![]() |
Functions | |
void | imProcessSplitYChroma (const imImage *src_image, imImage *y_image, imImage *chroma_image) |
void | imProcessSplitHSI (const imImage *src_image, imImage *h_image, imImage *s_image, imImage *i_image) |
void | imProcessMergeHSI (const imImage *h_image, const imImage *s_image, const imImage *i_image, imImage *dst_image) |
void | imProcessSplitComponents (const imImage *src_image, imImage **dst_image_list) |
void | imProcessMergeComponents (const imImage **src_image_list, imImage *dst_image) |
void | imProcessNormalizeComponents (const imImage *src_image, imImage *dst_image) |
void | imProcessReplaceColor (const imImage *src_image, imImage *dst_image, double *src_color, double *dst_color) |
void | imProcessSetAlphaColor (const imImage *src_image, imImage *dst_image, double *src_color, double dst_alpha) |
void | imProcessPseudoColor (const imImage *src_image, imImage *dst_image) |
void | imProcessFixBGR (const imImage *src_image, imImage *dst_image) |
void | imProcessSelectHue (const imImage *src_image, imImage *dst_image, double hue_start, double hue_end) |
void | imProcessSelectHSI (const imImage *src_image, imImage *dst_image, double hue_start, double hue_end, double sat_start, double sat_end, double int_start, double int_end) |
Split a RGB image into luma and chroma.
Chroma is calculated as R-Y,G-Y,B-Y. Source image must be IM_RGB/IM_BYTE.
luma image is IM_GRAY/IM_BYTE and chroma is IM_RGB/IM_BYTE.
Source and target must have the same size.
im.ProcessSplitYChroma(src_image: imImage, y_image: imImage, chroma_image: imImage) [in Lua 5]
im.ProcessSplitYChromaNew(src_image: imImage) -> y_image: imImage, chroma_image: imImage [in Lua 5]
void imProcessSplitHSI | ( | const imImage * | src_image, | |
imImage * | h_image, | |||
imImage * | s_image, | |||
imImage * | i_image | |||
) |
Split a RGB image into HSI planes.
Source image can be IM_RGB+IM_BYTE or IM_RGB+IM_FLOAT/IM_DOUBLE only. Target images are all IM_GRAY+IM_FLOAT/IM_DOUBLE.
Source images must normalized to 0-1 if type is IM_FLOAT/IM_DOUBLE (imProcessToneGamut can be used). See HSI Color Coordinate System Conversions for a definition of the color conversion.
Source and target must have the same size.
im.ProcessSplitHSI(src_image: imImage, h_image: imImage, s_image: imImage, i_image: imImage) [in Lua 5]
im.ProcessSplitHSINew(src_image: imImage) -> h_image: imImage, s_image: imImage, i_image: imImage [in Lua 5]
void imProcessMergeHSI | ( | const imImage * | h_image, | |
const imImage * | s_image, | |||
const imImage * | i_image, | |||
imImage * | dst_image | |||
) |
Merge HSI planes into a RGB image.
Source images must be IM_GRAY+IM_FLOAT/IM_DOUBLE. Target image can be IM_RGB+IM_BYTE or IM_RGB+IM_FLOAT/IM_DOUBLE only.
Source and target must have the same size. See HSI Color Coordinate System Conversions for a definition of the color conversion.
im.ProcessMergeHSI(h_image: imImage, s_image: imImage, i_image: imImage, dst_image: imImage) [in Lua 5]
im.ProcessMergeHSINew(h_image: imImage, s_image: imImage, i_image: imImage) -> dst_image: imImage [in Lua 5]
Split a multicomponent image into separate components, including alpha.
Target images must be IM_GRAY. Size and data types must be all the same.
The number of target images must match the depth of the source image, including alpha.
im.ProcessSplitComponents(src_image: imImage, dst_image_list: table of imImage) [in Lua 5]
im.ProcessSplitComponentsNew(src_image: imImage) -> dst_image_list: table of imImage [in Lua 5]
Merges separate components into a multicomponent image, including alpha.
Source images must be IM_GRAY. Size and data types must be all the same.
The number of source images must match the depth of the target image, including alpha.
im.ProcessMergeComponents(src_image_list: table of imImage, dst_image: imImage) [in Lua 5]
im.ProcessMergeComponentsNew(src_image_list: table of imImage) -> dst_image: imImage [in Lua 5]
Normalize the color components by their sum. Example: c1 = c1/(c1+c2+c3).
It will not change the alpha channel if any. Target must be IM_FLOAT or IM_DOUBLE.
im.ProcessNormalizeComponents(src_image: imImage, dst_image: imImage) [in Lua 5]
im.ProcessNormalizeComponentsNew(src_image: imImage) -> new_image: imImage [in Lua 5]
void imProcessReplaceColor | ( | const imImage * | src_image, | |
imImage * | dst_image, | |||
double * | src_color, | |||
double * | dst_color | |||
) |
Replaces the source color by the target color.
The color will be type casted to the image data type.
The colors must have the same number of components of the images.
Supports all color spaces and all data types except complex.
im.ProcessReplaceColor(src_image: imImage, dst_image: imImage, src_color: table of numbers, dst_color: table of numbers) [in Lua 5]
im.ProcessReplaceColorNew(src_image: imImage, src_color: table of numbers, dst_color: table of numbers) -> new_image: imImage [in Lua 5]
void imProcessSetAlphaColor | ( | const imImage * | src_image, | |
imImage * | dst_image, | |||
double * | src_color, | |||
double | dst_alpha | |||
) |
Sets the alpha channel in target where the given color occurs in source, elsewhere alpha remains untouched.
The color must have the same number of components of the source image.
If target does not have an alpha channel, then its plane=0 is used.
Supports all color spaces for source and all data types except complex. Images must have the same size.
im.ProcessSetAlphaColor(src_image: imImage, dst_image: imImage, src_color: table of numbers, dst_alpha: number) [in Lua 5]
Creates a pseudo color version of a GRAY image.
Images must have same size. Destiny must be IM_RGB/IM_BYTE.
The colors are created from gray values using them to index Hue angles from 0 to 360, and as Intensity values, with maximum Saturation.
im.ProcessPseudoColor(src_image: imImage, dst_image: imImage) [in Lua 5]
im.ProcessPseudoColorNew(src_image: imImage) -> new_image: imImage [in Lua 5]
Fix BGR order to RGB. Images must match. And must have color space RGB.
im.ProcessFixBGR(src_image: imImage, dst_image: imImage) [in Lua 5]
im.ProcessFixBGRNew(src_image: imImage) -> new_image: imImage [in Lua 5]
void imProcessSelectHue | ( | const imImage * | src_image, | |
imImage * | dst_image, | |||
double | hue_start, | |||
double | hue_end | |||
) |
Uses a hue interval to isolate where color predominates. Images must match. And must have color space RGB.
im.ProcessSelectHue(src_image: imImage, dst_image: imImage, hue_start, hue_end: number) [in Lua 5]
im.ProcessSelectHueNew(src_image: imImage, hue_start, hue_end: number) -> new_image: imImage [in Lua 5]
void imProcessSelectHSI | ( | const imImage * | src_image, | |
imImage * | dst_image, | |||
double | hue_start, | |||
double | hue_end, | |||
double | sat_start, | |||
double | sat_end, | |||
double | int_start, | |||
double | int_end | |||
) |
Uses a hue, saturation, intensity intervals to isolate where color predominates. Images must match. And must have color space RGB.
im.ProcessSelectHSI(src_image: imImage, dst_image: imImage, hue_start, hue_end, sat_start, sat_end, int_start, int_end: number) [in Lua 5]
im.ProcessSelectHSINew(src_image: imImage, hue_start, hue_end, sat_start, sat_end, int_start, int_end: number) -> new_image: imImage [in Lua 5]