I have a 3rd party component which requires me to give it the bitsperpixel from a bitmap.
What\'s the best way to get \"bits per pixel\"?
My starting point is th
var source = new BitmapImage(new System.Uri(pathToImageFile)); int bitsPerPixel = source.Format.BitsPerPixel;
The code above requires at least .NET 3.0
http://msdn.microsoft.com/en-us/library/system.windows.media.imaging.bitmapimage.aspx