cvtcolorcv
Convert the image, handle, to a different color space.
Syntax
R = cvtcolorcv(handle, colorspace...)
R = cvtcolorcv(handle, colorspace, channels)
Inputs
- handle
- Handle of an image.
- colorspace
- Color space code. Valid values are 0 to 142.
- channels
- Optional parameter specifying channels in the output. Default value is 0, indicating R will have the same number of channels as handle.
Outputs
- R
- Handle of the output image in the color space specified.
Example
handle = imreadcv('image1.jpg');
colorspace = 50;
R = cvtcolorcv(handle, colorspace);