[This is preliminary documentation and subject to change.]
Alpha values per pixel are only supported for 32-bit-per-pixel BI_RGB. This formula is defined as :
typedef struct {
BYTE Blue;
BYTE Green;
BYTE Red;
BYTE Alpha;
};
This is represented in memory as:
31:24 |
23:16 |
15:08 |
07:00 |
Alpha |
Red |
Green |
Blue |
Global Alpha Blending Settings
Bitmaps may also be displayed with a transparency factor applied to the entire bitmap. Any bitmap format can be displayed with a global constant alpha value by setting SourceConstantAlpha in the BLENDFUNCTION structure. The global constant alpha value has 256 levels of transparency, from 0 (entire bitmap is completely transparent) to 255 (entire bitmap is completely opaque). The global constant alpha value is combined with the per-pixel alpha value.