Media (Intel® Video Processing Library, Intel Media SDK)
Access community support with transcoding, decoding, and encoding in applications using media tools like Intel® oneAPI Video Processing Library and Intel® Media SDK
Announcements
The Intel Media SDK project is no longer active. For continued support and access to new features, Intel Media SDK users are encouraged to read the transition guide on upgrading from Intel® Media SDK to Intel® Video Processing Library (VPL), and to move to VPL as soon as possible.
For more information, see the VPL website.

Color conversion via VPP

Oh_i_
Beginner
891 Views

Hi,

 

I'm trying to encode color images and the only color format supports is NV12 (am I right about it?) and I cant find any reference about "how can I convert from RGB24 or RGB32 to NV12 using IMSDK", the only reference to an example is:

http://software.intel.com/en-us/articles/intel-media-sdk-tutorial-simple-6-encode-ipp-cc

but the only option there is using IPP, which I don't want to use this time....

any example?

tutorial?

Thanks

0 Kudos
6 Replies
Petter_L_Intel
Employee
891 Views

Hi,

There is in fact a Media SDK tutorial sample for this use case (RGB32). Check out the sample named "simple_6_encode - d3d - vpp_preproc".

Note that RGB24 is not a supported format by Media SDK. It's was deprecated a long time ago.

Regards,
Petter

0 Kudos
Oh_i_
Beginner
891 Views

Hi,

Thanks, for the quick reply.

Some Q's:

1. Is color encoding is only of NV12 format?

2. RGB3 is not supports, but can I convert from RGB3 to NV12?

Thanks

0 Kudos
Petter_L_Intel
Employee
891 Views

Hi,

Yes. The Media SDK encoder only supports NV12 surface input.

I assume by RGB3 mean RGB24? Both essentially referring to a RGB 8 bit per channel color space without alpha.  The SDK does not support conversion from that color space format to NV12.

If you need such conversion you have to rely on Intel IPP, other color space conversion packages or implement your own routine. 

Regards,
Petter

0 Kudos
Aaron_Z_
Beginner
891 Views

Hi,

Can I convert using VPP from

{ MFX_FOURCC_NV12, MFX_CHROMAFORMAT_YUV420 } to

{ MFX_FOURCC_YUY2, MFX_CHROMAFORMAT_YUV422 } ?

Thanks

0 Kudos
Surbhi_M_Intel
Employee
891 Views

Hi Aaron, 

Yes, you can convert from NV12 to YUY2 using VPP in Media SDK. Please refer to sample_vpp code in the sample package which is configured to convert the color format. 

In general for a new query please start a new post so that we can track the questions separately and provide support sooner. Hope that helps!

Thanks,
Surbhi

 

0 Kudos
Hitesh_V_
Beginner
891 Views

Hi Surbhi,

I am new to Intel Media SDK. I am doing some PoC with the SDK where I need to decode H.264 video into YUV422 (UYVY). I checked both the sample "simple_6_decode_vpp_postproc" and change few VPP o/p parameters ( VPPParams.vpp.Out.FourCC = MFX_FOURCC_YUY2, VPPParams.vpp.Out.FourCC = MFX_FOURCC_YUY2, VPPParams.vpp.Out.CropW = VPPParams.vpp.In.CropW, VPPParams.vpp.Out.CropH = VPPParams.vpp.In.CropH, and bitsPerPixel = 16) but still the generated YUV file is NV12 only.

Resize is working very well but color conversion is not working with above change. Am I doing in mistake in the configurations?

Please advise.

- HRV

0 Kudos
Reply