I am converting an Win32 medical image processing application to .Net. I am
new the UI side of .Net applications and I am trying to display a grayscale
images at a reasonable frame rate (5-10 frames per second). The application
captures 1024x768 12-bit grayscale pixels, which I am storing in managed
array. My initial thought, was to create a bitmap and copy the captured data
to the BitmapData section of an image. I initially tried to create the Bitmap
using the PixelFormat.Format16bppGrayScale. After having a bit of trouble, I
read in a few other news group postings that the Format16bppGrayScale option
is not really supported. Is that true? I also noticed that images can have an
attributes and the ImageFlags attribute has a value to specify ColorSpaceGray
and also has a flag called Caching, which both seem like attributes that I
would want to use. I have not found much documentation or examples on how
they can be used. Can anyone point me in the correct direction?
From the Win32 app, I saved a bitmap of an image then constructed a .Net
image by reading that file. I noticed that imaged was created with the
PixelFormat.Format8bppIndexed and was using a grayscale color palette. It
that the better method of setting up and display grayscale images?
Am I on the right track, or should I be taking a different approach?
Any thoughts will be appreciated.