bmp file format, pixels, rgb triple and quad

Hello!


I am just learning, therefore my questions are not professional yet.

A question on bitmap file format: if the bmp file has 24-bits per pixel, then each pixel is 3 bytes.

Does it mean that for a 24-bit image only RGB triple is used, and not RGD quad?


Thank you!

it seems I can't edit my questions here. I would like to add: does it mean that if I have a 32-bit bmp it will always be an RGBQUAD,

while 24-bit one is always RGBTRIPLE?

Are you referring to the Windows .bmp format? If so, yes, you're right, 32-bit formats are stored as 4 bytes and 24-bit formats are stored as 3 bytes, HOWEVER, each line is always padded to a 32-bit boundary.

The Wikipedia entry has all the details.

bmp file format, pixels, rgb triple and quad
 
 
Q