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.

creating video output channe

Other Parts Discussed in Thread: TVP5146

hi,

as i stil trying to understand the basics of the DM6437 in the video_preview pfiject i face to the following issue.

as i understand the video output channel is being configed here

  PSP_VPFE_TVP5146_ConfigParams tvp5146Params =
       VID_PARAMS_TVP5146_DEFAULT;
  PSP_VPFECcdcConfigParams      vpfeCcdcConfigParams =
       VID_PARAMS_CCDC_DEFAULT_D1;
  PSP_VPBEOsdConfigParams vpbeOsdConfigParams =
       VID_PARAMS_OSD_DEFAULT_D1;
  PSP_VPBEVencConfigParams vpbeVencConfigParams;

as i enter the "VID_PARAMS_OSD_DEFAULT_D1 " i want to change the colorformat from "FVID_YCbCr422_INTERLEAVED" to "FVID_YCbCr422_PLANAR" or "FVID_RGB565_INTERLEAVED"

as i understans (corect me if i'm wrong) the FVID_YCbCr422_INTERLEAVED is basicaly make the pixels be in the order of y1cb2y2cr2y3cb4y4cr4

in the FVID_YCbCr422_PLANAR is it make the image aragmaent memory y1y2y3 and all the luma is being made continuous order in the memory. is it corect? if yes, what else should i change in order that this format will work?

- "FVID_RGB565_INTERLEAVED" - is this format make the same as FVID_YCbCr422_INTERLEAVED and make the pixels arange in the memory as r1g1b1r2g2b2 or is it work in another way?

 

is it all conect to the chanel creation?

  /* create video output channel, venc */
  if (status == 0) {
    PSP_VPBEChannelParams vpbeChannelParams;
    vpbeChannelParams.id     = PSP_VPBE_VENC;
    vpbeChannelParams.params = (PSP_VPBEVencConfigParams *)&vpbeVencConfigParams;
    hGioVpbeVenc = FVID_create("/VPBE0",IOM_INOUT,NULL,&vpbeChannelParams,NULL);
    status = (hGioVpbeVenc == NULL ? -1 : 0);

as i change the colorformat from "FVID_YCbCr422_INTERLEAVED" to "FVID_YCbCr422_PLANAR" the status get -1 and does not work, what should i do?

 

sorry for the dummie quesions

thank you for your help

vadim

  • Vadim said:
    as i understans (corect me if i'm wrong) the FVID_YCbCr422_INTERLEAVED is basicaly make the pixels be in the order of y1cb2y2cr2y3cb4y4cr4

    This is correct.

    Vadim said:
    in the FVID_YCbCr422_PLANAR is it make the image aragmaent memory y1y2y3 and all the luma is being made continuous order in the memory. is it corect? if yes, what else should i change in order that this format will work?

     

    Planar would indicate individual buffers for each portion of the color space so your assertion there is correct, however I do not believe this is supported by the driver as the underlying hardware expects interleaved and there is no mention of planar in the driver user's manual. You can convert the image to and from planar in software, for an example you may want to look at the resizer examples in C:\dvsdk_1_01_00_15\psp_1_00_02_00\pspdrivers\system\dm6437\bios\dm6437_evm\src\video\sample\resizer as they have a function that converts from interleaved to planar so that you can see the output in the CCS image viewer (which happens to only support planar).

    Vadim said:
    - "FVID_RGB565_INTERLEAVED" - is this format make the same as FVID_YCbCr422_INTERLEAVED and make the pixels arange in the memory as r1g1b1r2g2b2 or is it work in another way?

    It is similar to the YCbCr interleaved in that it is interleaved but the color space is obviously different and the interleaving is as well. In the case of RGB 565 each pixel takes up a 16 bit value so much like the YCbCr 4:2:2 there are two bytes per pixel, however instead of simply dropping half the chroma values to achieve this, the RGB packs a 5 bit R, 6 bit G, and 5 bit B into a single 16 bit value, so you have something like 0bRRRRRGGGGGGBBBBB. You can read more about these formats and converting them on the internet, one page that talks about extracting the format can be found here. Note that this RGB565 format will only work if you open a OSD window not a VID window.

    Vadim said:
    as i change the colorformat from "FVID_YCbCr422_INTERLEAVED" to "FVID_YCbCr422_PLANAR" the status get -1 and does not work, what should i do?

    As mentioned above the driver only supports the interleaved format, you have to do any planar <-> interleaved conversions in software.

  • thanks alot!!!

    it helps me very much and sorry for the dummie questions [:D]