bitmapframe

BitmapFrame in WPF ComboBox

I have a dialog that lets the user pick a custom icon. Loaded icons are displayed in a combobox in which the user makes the selection. Here is the XAML code for the combobox: <ComboBox Style="{DynamicResource IconComboBox}" ItemTemplate="{StaticResource IconTemplate}" ItemsSource="{Binding Icons, RelativeSource={RelativeSource Fin...

BitmapFrame in another thread

Hi I am using a WPF BackgroundWorker to create thumbnails. My worker function looks like: private void work(object sender, DoWorkEventArgs e) { try { var paths = e.Argument as string[]; var boxList = new List<BoxItem>(); foreach (string path in paths) { if (!string.IsNullOrEmpty(path)) ...

Convert WPF BitmapSource to Icon for window

I have a 16x16 .png file which I have loaded as an ImageSource (BitmapSource) and it is working fine when I use it on an Image in a tabcontrol header. I now want to use that same image in a floating window (inherited from the WPF Window class) when the user drags the document tab. (This is AvalonDock which I have tweaked to allow images...

Problem with BitmapFrame rendering (created from byte array) in C#

Hi there, Here is the situation: I have got the array of bytes containing the bitmap header together with the bitmap data. I know the offset of data, and I need to generate BitmapFrame for later rendering. I wanted to avoid array cells copying and created a wrapper for a part of the array ( ArraySegment ). Then I render this bitmap...