TdxAlphaColors.GetBrightness(TdxAlphaColor) Method
In This Article
Extracts the brightness color component value from the specified color.
#Declaration
Delphi
class function GetBrightness(AColor: TdxAlphaColor): Single; static;
#Parameters
Name | Type |
---|---|
AColor | Tdx |
#Returns
Type |
---|
Single |
#Remarks
The GetHue, GetSaturation, and GetBrightness functions are used to convert the TdxAlphaColor value passed as the AColor parameter to the HSB representation of an RGB color model. A value returned by the GetBrightness function is located within the range between 0 and 1 (inclusive), and corresponds to the specified color’s relative brightness (as a percentage).
Note
The specified color’s alpha is not involved in calculating the brightness value.
See Also