This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Linux/TMS320DM8148: V4L2 Capture in NV12 causes corrupted color plane

Part Number: TMS320DM8148
Other Parts Discussed in Thread: TVP5150

Tool/software: Linux

I am seeing color bleeding from the bottom of imagery to top when capturing YUV data in NV12 format. This problem does not exist when capturing in YUYV mode

It appears that the Luma component from the bottom of the image is being displayed as Croma near the top of the image. I often see the purple and green colors when Luma/Chroma are swapped.

The issue is very similar to this posting:

https://e2e.ti.com/support/dsp/davinci_digital_media_processors/f/716/p/382147/1346533

-> I have discovered that if the camera outputs at least 30 lines of vertical blanking, that the problem goes away. This is the case for both embedded sync systems (like HD-SDI) as well as discrete VSync/Hsync line capture.

-> Can you point me to the relevant code (I think on M3 processor) where the addressing is being setup for NV12 capture.  I think there is a bug in there.

Thanks, Steve

  • Hi ,

    Which software release are you using?
    Can you tell us about your usecase.

    Regards,
    Anuj
    Pathpartner Technology Pvt Ltd
  • Thank you for your response.

    We are using 5_05_02_00

    The simplest way to reproduce this would be with NTSC analog camera acquisition through a TVP5150.

    If you set the output pixel format to V4L2_PIX_FMT_YUYV then the acquisition works fine

    If you set the output pixel format to V4L2_PIX_FMT_NV12, then you see the imagery exactly as shown in this posting:

    https://e2e.ti.com/support/dsp/davinci_digital_media_processors/f/716/p/382147/1346533

    I work at the same company as Tamo2 (who posted above) This posting was never resolved, and we have been using V4L2_PIX_FMT_YUYV pixel format for NTSC (BT.656) capture from the TVP5150.

    Unfortunately we now have a customer who is showing this issue with their 1080P camera, and our system requires NV12 capture for the large pixel format to work correctly.

    Tamo2 has also suggested that there could be a problem with the color space conversion.

    Best Regards, Steve