Where do i specify the colors in a bitmpa picture?
-
-
If i want to save a bitmap to the disk, i first write BITMAPFILEHEADER struct to the disk and then a BITMAPINFO struct, but where do i specify the colors? I have an array of RGBQUAD's that contain all the colors but where do i specify them? Thanks
the palette comes after the BITMAPINFOHEADER struct and before the pixel data -c
Garbage collection, making life better - for weenies!
Image Processing - just like mom used to make.
-
the palette comes after the BITMAPINFOHEADER struct and before the pixel data -c
Garbage collection, making life better - for weenies!
Image Processing - just like mom used to make.
-
a palette is what you use to define the colors for a colormapped image (1,4 or 8 bits per pixel). if you're writing a 24 or 32 bpp BMP/DIB, you don't need a palette. in a BMP/DIB, the palette is the set of (up to) 256 RGBQUADs after the BITMAPINFOHEADER. after that comes the image data, formatted in any of a dozen or more ways, depending on bit depth, compression , JPG , PNG, etc.. -c
Garbage collection, making life better - for weenies!
Image Processing - just like mom used to make.