Convert RGB image to YUV color model
Function
CuviStatus rgb2yuv(CuviImage* srcImage,
CuviImage* dstImage,
CuviStream* stream = NULL);
|
Parameters
| Name
|
Type
|
Description
|
| srcImage
|
CuviImage*
|
Input RGB image
|
| dstImage
|
CuviImage*
|
Output YUV image
|
| stream
|
CuviStream*
|
GPU stream ID for execution
|
Image Type Support
| Input
|
Output
|
| 8uC3
|
8uC3
|
| 16uC3
|
16uC3
|
Sample
RGB Image
|
YUV Image
|
Example
CuviImage* gimg = new CuviImage(size,img->depth,img->nChannels);
CuviImage* gout = new CuviImage(size,img->depth,img->nChannels);
//Upload RGB data to GPU
gimg->upload(img->imageData,img->widthStep);
//function call
cuvi::colorOperations::RGB2YUV(gimg,gout);
|