
24 bit color bitmap creation
I am trying to read a rasterized graphic format from disk, convert to a
bitmap and display it in a picturebox. Am ia correct in assuming that a
24 bit bimap requires 3 bytes of data per pixel? What's the easiest way
to declare this, as an array of 3 bytes?
The thing that I don't understand is I originally loaded the file and
displayed it in the picturebox as 8 bit and it looked fine (looked like
24 bit color). I set up the color table as RGBQUAD and altered the
colors from 0 - 255 in greyscale. The biBitCount field was set to 8.
Why did this happen? The only reason why I noticed a problem was when I
tried Jim Deutch's code for fading a bitmap on a picturebox. When I
tried basically the same bitmap header (8 bit color, etc), then the
result was true 8 bit color (much less resolution).
Sorry this sounds cryptic. Anyone have an idea?