CRasterImage::ReplaceColor![]()
void ReplaceColor( ReplaceColor( unsigned int
srcColor, unsigned int dstColor
);
void ReplaceColor( ReplaceColor( unsigned int
srcColorMin, unsigned int srcColorMax, unsigned int
dstColor );
Parameters
| srcColor | color to be replaced |
| dstColor | affected pixels color will be replaced by dstColorvalue |
| srcColorMin | minimum value of source color to be replaced |
| srcColorMax |
maximum value of source color to be replaced |
Remarks
The ReplaceColor function replaces all srcColor pixels with color value specified by dstColor parameter.
The second version of the function replaces all pixels with color in specified color range with dstColor value. A color is in specified range if red component of the color lies between red components of srcColorMin and srcColorMax, the green color component lies between green color components of srcColorMin and srcColorMax and so on.
The 32 bit unsigned int color value format used by CRasterImage object is compatible with COLORREF type values produced by Win32 RGB macro. If storage type of the image is GL_RGBA then highest byte of the unsigned int color value specifies the alhpa channel value.
This function is available since ClassGL version 3.6.10.
See Also
![]()
| © 2003 Solid Graphics, All rights reserved. |
| To view this site, we require use of either Netscape Navigator 4.0 or higher or Internet Explorer 4.0 or higher. |