Media (Intel® oneAPI Video Processing Library, Intel Media SDK)
Access community support with transcoding, decoding, and encoding in applications using media tools from Intel. This includes Intel® oneAPI Video Processing Library and Intel® Media SDK.

YUV output problem after YV12 to NV12 conversion

shavkat_n_
Beginner
227 Views

Hello

I'm doing color conversion YV12(YUV420) to NV12 using ffmpeg using sws_getCachedContext & sws_scale. Then I feed it IntelMedia VPP & Encoder. I have output but it is as following.

Y(luma) seem ok, but there seem to be a mismatch with UV(chroma) planes. Please give a hint if you recognize this problem.

912345_1minvideo.mp4_20170420_113501.028.jpg

0 Kudos
1 Reply
shavkat_n_
Beginner
227 Views

I found the reason for this issue. Seems output slice linesize was being bitshifted and got cut in half. 

Isn't avcodec_get_chroma_sub_sample for AVPixelFormat of AV_PIX_FMT_NV12 supposed to output 0 for horizontal shift ??

Reply