ImageEn, unit iexBitmaps

TIEBitmap.AlphaFill

TIEBitmap.AlphaFill


Declaration


procedure AlphaFill(Value: Byte); overload;
procedure AlphaFill(StartValue, EndValue: Byte; Direction: TIEGradientDir = gdVertical); overload;


Description


Sets the transparency of the alpha channel. Either filling the entire alpha channel to a single value, or graduating from one value to another (gradient transparency).

0 is transparent, 255 is opaque, 1 - 254 are partially transparent.




Example


// Set image as fully transparent
IEBitmap.AlphaFill( 0 );

// Set image as fully opaque
IEBitmap.AlphaFill( 255 );

// Set image as 50% transparent
IEBitmap.AlphaFill( 128 );

// Graduate the transparency from fully transparent on the left to fully opaque on the right
IEBitmap.AlphaFill( 0, 255, gdHorizontal );


See Also


- Alpha
- AlphaChannel
- AlphaFillRect
- Fill
- FillRect
- GradientFill
- GradientFillRect