Specifications

Color Space Conversion
9-9
9
The weights to compute true luminance from linear red, green and blue are
these:
Y = 0.212671 * R + 0.715160 * G + 0.072169 * B
Conversion from Gray Scale to Color (Pseudo-color)
This section describes the conversion of gray scale image to pseudo color.
GrayToColor
Converts a gray scale to
color image.
void iplGrayToColor (IplImage*
srcImage
, IplImage*
dstImage,
float
FractR,
float
FractG,
float
FractB
);
srcImage
The source image. See Table 9-4 for a list of
valid source and resultant image
combinations.
dstImage
The resultant image. See Table 9-4 for a list
of valid source and resultant image
combinations.
FractR,FractG,FractB
The red, green and blue intensities for
image reconstruction. See Discussion for a
list of valid
FractR
,
FractG
,and
FractB
values.
Discussion
The function iplGrayToColor() converts a gray scale source image
srcImage
to a resultant pseudo-color image
dstImage
. Table 9-4 lists the
valid combinations of source and resultant image bit data types for
conversion from gray scale to color.