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.

DM6437 YCbCr to RGB conversion

Other Parts Discussed in Thread: TVP5146

Hi,

I'm capturing video data from the S-video input of the DM6437 evaluation board.

I need RGB values of the image captured. I've problems on conversion from YCbCr to RGB.

I'm using standart transformation parameters but the RGB image I obtain have saturation of the red or blue colors on the high frequency edges of the objects on the image.

Can someone refer a solution for this.

Note: Is there a way of connecting RGB component inputs to the DM6437 evaluation board. If so I will  pretty easier solve my problem

Thank you

  • RIFAT BENVENISTE said:
    I'm using standart transformation parameters but the RGB image I obtain have saturation of the red or blue colors on the high frequency edges of the objects on the image.

    So it sounds like you have some of the transformation already implemented and you are getting noise on the output? If this is the case could you post a picture of the output you are getting? This is certainly something that is possible but I do not know of any example for DM6437 that does this.

    RIFAT BENVENISTE said:
    Note: Is there a way of connecting RGB component inputs to the DM6437 evaluation board. If so I will  pretty easier solve my problem

    You could fashion a daughterboard for the EVM that could do this, however the EVM hardware out of the box is not really capible of this, as it only uses a TVP5146 with composite and S-Video inputs.

  • Below is the RGB transformed image I captured by CCS As its seen there are some green dots on the word vivident and also there is a blue colored noise on the dark regions of the image

    I searched a daughterboard with component RGB input but I couldn't find one. EPIC advised to use TVP7000 EVM. I've ordered one but I don't know how to bypass the TVP5146 and connect the TVP7000 EVM to the DM6437 EVM.

     

  • RIFAT BENVENISTE said:
    Below is the RGB transformed image I captured by CCS As its seen there are some green dots on the word vivident and also there is a blue colored noise on the dark regions of the image

    Assuming the image is getting into the DM6437 properly this would certainly seem to be an issue somewhere during the conversion process, though that much is probably obvious. I would look for a place that the pixel data is breaking some threshold, as it looks like certain portions of the image with specific colors are being subject to the noise which tells me something in the conversion algorithm breaks beyond (or at) certain incoming pixel values. It may also be worth sending some test data through the conversion process, such as a set of color bars or other patterns that can help to find what values are causing the noise and use that to trace through the algorithm to find the problem.

    RIFAT BENVENISTE said:
    I searched a daughterboard with component RGB input but I couldn't find one. EPIC advised to use TVP7000 EVM. I've ordered one but I don't know how to bypass the TVP5146 and connect the TVP7000 EVM to the DM6437 EVM.

    This is a tougher problem, as the TVP7000 EVM has its own proprietary interface and will not connect directly to the DM6437 EVM, and even once it is physically connected somehow there will be some sofware driver modifications required to make it work. For a physical interface you would have to create some sort of daughterboard adapter to bridge between the TVP7000 EVM and the DM6437 EVM. From a software perspective you will probably want to start with the existing capture driver and modify it to work with the TVP7000.

  • Hi

    I am new to DSP Board programming, I am using the EVM DM6437, apparently the output is in YCbCr format but I need it to be in RGB. is there anyway you could help me.

  • I have a header file that I've wrote, but can not give the effort and time I've spend free of charge. If you want to write a code  I would recommend Charles Poynton's book about digital video  that was very useful for me.
  • well ,how much you rekon your code is worth?

  • If you are interested to buy please send me a blank email on rifatbenveniste@gmail.com address. I can post the worth and payment details

  • mohsen said:
    I am using the EVM DM6437, apparently the output is in YCbCr format but I need it to be in RGB.

    Just to be clear here, I think what Rifat here has is a conversion routine for in the processor itself, that is the board takes in a YCbCr image and this converts it to RGB in internal memory, as opposed to making the outputs of the DM6437 provide an RGB signal. If when you say output you mean the output of the EVM itself in RGB than Rifat's code will not be of much help.

    Also, I should have mentioned this back when Rifat asked about this, though at the time I did not as I was just focused on the problem itself and not the bigger picture, there are some conversion functions in IMGLIB, I am not sure if Rifat was basing his conversion off of these or not though.

  • As I remember IMGLIB Converts to RGB565 format which was inconvenient for me. Also I've had some porblems on data format using IMGLIB therefore I worte my own code with RGB888 data output. The point Bernie Thompson  emphasized is true. The code I wrote converts YCbCr to RGB  in internal memory for image processing purposes it does not give any RGB output from the EVM. 

  • Try out this equation:

    |R|    |Y - 16|           |1.164   0        1.596 |
    |G| = | U      |   X      |1.164   -0.391   -0.813|
    |B|    | V       |            |1.164   2.018    0     |

    Make sure you don't mess the signs of the equation, otherwise you will see the different coloured dots on the image (same as there in your uploaded image)

    Mitul (www.einfochips.com)