![]()  | 
![]()  | 
![]()  | 
![]()  | 
![]()  | 
This version of this document is no longer maintained. For the latest documentation, see http://www.qnx.com/developers/docs. | 
Extract color brightness
int PgGrayValue( PgColor_t color );
ph
This macro converts a composite color into its corresponding level of gray. The calculation is based on 30% red, 59% green, and 11% blue, resulting in a value between 0 and 255.
The gray component of the color.
// Convert pal[i] into monochrome pal[i] = PgGray( PgGrayValue( pal[i] ) );
Photon
| Safety: | |
|---|---|
| Interrupt handler | No | 
| Signal handler | No | 
| Thread | No | 
PgBlueValue(), PgCMY(), PgColor_t, PgGreenValue(), PgHSV(), PgRedValue(), PgRGB(), PgSetFillColor(), PgSetFillDither()
"Color" in the Raw Drawing and Animation chapter of the Photon Programmer's Guide
![]()  | 
![]()  | 
![]()  | 
![]()  |