Intel® Integrated Performance Primitives
Deliberate problems developing high-performance vision, signal, security, and storage applications.
6708 Discussions

Converting from pixel-order (C3) to planar (P3) data ?

gari154
Beginner
305 Views
Hi all,

I have a little problem to convert image color from pixel-order RGB to planar data YCbCr. Anybody know how to do that ? I need your suggestions.

Thanks,

Gunawan
0 Kudos
3 Replies
Vladimir_Dudnik
Employee
305 Views
Hi Gunawan
to find any particular functions in Image Processing domain. For example, convertion like you mention can be done with using the following functions (described in ippi.h file)
Code:
/* Pixel to Plane */
IPPAPI(IppStatus, ippiRGBToYUV_8u_C3P3R,( const Ipp8u* pSrc, int srcStep ,
       Ipp8u* pDst[3], int dstStep, IppiSize roiSize))
/* Plane to Pixel */
IPPAPI(IppStatus, ippiYUVToRGB_8u_P3C3R,(const Ipp8u* const pSrc[3], int srcStep,
       Ipp8u* pDst, int dstStep, IppiSize roiSize))
Regards,
Vladimir
0 Kudos
gari154
Beginner
305 Views
Hi Vladimir,

Thanks for your suggestion. However I think YUV and YCbCr are different( based on the convertion formula on IPP reference manual ). I found "C3P3R" on RGBToYUV but not on RGBToYCbCr.

Thanks,
Gunawan
0 Kudos
Vladimir_Dudnik
Employee
305 Views
You are right, there might be difference between YUV and YCbCr (depends how you define these color spaces). The exact formulae used in this functions are described in IPP documentation. By the way, we also have ippiRGBToYCbCr_JPEG_8u_C3P3R function in ippJP library (see ippj.h file)
Regards,
Vladimir
0 Kudos
Reply