ImageEn, unit hyieutils

TColor2TRGBA


Declaration

function TColor2TRGBA(cl: TColor): TRGBA; overload;
function TColor2TRGBA(cl: TColor; Transparency: Integer): TRGBA; overload;


Description

Converts a TColor value to TRGBA, optionally using the alpha value of the color value, i.e. $AABBGGRR, or an explicit transparency.


Example

// Pass an alpha value
rgba := TColor2TRGBA( clRed, 255 );

// Get alpha from the color value
rgba := TRGBA2TRGB( $000000FF );


See Also

CreateRGBA
TRGB2TRGBA
TRGB2TColor
TRGBA2TRGB