TCustomBitmap32.MasterAlpha

property MasterAlpha: TColor32;

Description

When blending a bitmap to the screen or to another bitmap, MasterAlpha normally controls the blending factor. The per-pixel opacity, stored in the blended bitmap, is premultiplied with MasterAlpha. If the MasterAlpha property is $00, the bitmap will be fully transparent, if it is equal to $FF, only per-pixel opacity, stored in bitmap’s alpha channel is used. This property is used only for bitmap blending, it does not affect pixel/line drawing and other similar routines.

When blending bitmaps in dmCustom draw mode, this property may be used for other purposes. Custom combining routine may use all 32 bits of MasterAlpha.

If the bitmap is in dmBlend draw mode and MasterAlpha is not in the [0…255] range, the blending result is not specified, it is your responsibility to keep MasterAlpha consistent with current draw mode.

See Also

DrawMode, Color Types