3 Replies Latest reply: Mar 14, 2013 1:41 PM by Rallymax-forum RSS

    Exporter plugin: PrPixelFormat PrPixelFormat_YUV_420_MPEG4_FRAME_PICTURE_PLANAR_8u_*

    nvenc4everyone Community Member

      I've been struggling to get my Exporter plugin to work with any of the new planar PrPixelFormats (adobe Premiere Pro 6.0.3):

          PrPixelFormat_YUV_420_MPEG4_FRAME_PICTURE_PLANAR_8u_709

          PrPixelFormat_YUV_420_MPEG4_FRAME_PICTURE_PLANAR_8u_601

          PrPixelFormat_YUV_420_MPEG4_FRAME_PICTURE_PLANAR_8u_709_FullRange

          PrPixelFormat_YUV_420_MPEG4_FRAME_PICTURE_PLANAR_8u_601_FullRange

          ...

       

      My plugin uses an input format not natively supported by the SDK:  "NV12"

      NV12 contains the same pixel/chroma information as YV12;  the difference is in the chroma-plane packing.  In YV12, each of the Cb and Cr planes is stored as a solo plane (at half-height x half-width).  In NV12, each Cb+Cr sample is grouped into a 16-bit value, then packed into a single plane.  The same information is there, the only difference is that YV12 has 2 chroma-planes (each with total bytesize '1/4 Y'), and NV12 has 1 chroma-plane (with total bytesize '1/2 Y'.)

       

      Anyway,

      so far I've only been successful using a 4:4:4 YUV PrPixelFormat, then having my user-plugin manually convert the 4:4:4 into a NV12 format.

      (PrPixelFormat_VUYX_4444_8u).  When I try any of the sequenceRenderSuite->RenderVideoFrame(...), I get garbled pixeldata.

      The Y (luma) plane is correct, but the Chroma-data appears to be missing.

       

      For example, I expect PrPixelFormat_YUV_420_MPEG4_FRAME_PICTURE_PLANAR_8u_709 to store the Cb/Cr plane immediately after the Y plane.  However, it looks like renderVideoFrame( PrPixelFormat_YUV_420_MPEG4_FRAME_PICTURE_PLANAR_8u_709 ) simply returns the 'Y' plane repeated 3 times.

       

      The SDK documentation doesn't go into detail about the new planar pixel formats?  Is there an online reference or other doc?