Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

how to write NV12 byte buffer into a image using opencv?

Hi I want to save the NV12 video buffer into series of the image file. I want to know how to do ?

how to write NV12 byte buffer into a image using opencv?

Hi I want to save the NV12 video buffer into series of the image file. I want to know how to do ?

In NV12 the chroma is stored as interleaved U and V values in an array immediately following the array of Y values. Therefore, to get to the UV array we need to skip past the Y array - IE width of each pixel line (m_stride) times the number of pixel lines in the image (m_imageHeightInPixels)