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.

DVRRDK350 TI816X add osd after decoder,osd display abnormal

Hello:

my link chain is: (A8 host socket recv)---->ipcbitsOutA8Host---->ipcbitsInM3Video--->dec---->ipcOutM3video---->ipcInM3Vpss--->ipcframeOutVpss----{process link:ipcframeInDsp--->dsp_alg}------>swms--->display

I use mcfw api Vcap_setDynamicParamChn() to control the osd display or not,if i disable the osd, display is right,see the file1

when i enable the osd, the osd window display abnormal,see the file2 

2. I have try the link capture->ipcframeOutVpss--{process link:ipcframeInDsp--->dsp_alg}--->swms-->display

this link work good,every display right,so my osd work well

3.my question : why after decoder,add osd display abnormal

   if anyone know something about this question,please send email to me: robin4500@126.com

thanks very much!

wish you have good time!

  • Try setting decodLink displayDelay to 2 and check if you still see the issue. Issue could be because decoder output buffer should be treated as readonly and not modified as it is used as reference buffer for future buffer. Adding SWOSD modifies the reference buffer content

  • hello Badri:

       I have try set decoderLink displayDelay to 2(also try 3),still see the issue.

       some other person also use link chain like me ,they display well,but they also don't know the reason!

  • Hi Badri:

              I think I solve the problem,I change the link as:  (A8 host socket recv)---->ipcbitsOutA8Host---->ipcbitsInM3Video--->dec---->ipcOutM3video---->ipcInM3Vpss--->swms--->ipcframeOutVpss----{process link:ipcframeInDsp--->dsp_alg}------>display

    the reason is you mention: decoder output buffer should treated as readonly!

      add  osd after swmlink, swmslink will alloc a new mem for frame,then modify data.

    but this link not I want, I will decode 2 stream,so don't have enough swmslink to use.(display also need swmslink),so there are anyother method to solove the question?

    I want to make decoder device,for example 16ch,so swms only have 4,so I think there are other way to solve the probelm, wish you replay!

    wish you happy every day!

  • I think the best way to solve the issue allow to modify data in the decoderLink output buff. is there anyway to implement this method?

    if can.how to mofify the rdk

  • Settign displayDelay should have worked. Check if the setting you did actually took effect by printing the H264 decoder static params.

  • Hello:

        I am sorry,set displayDelay can't work,and there another issue, the osd display not complete,you can see the video,the start position is not right,(i have try other link chain,it's display ok), in the video ,saw the osd start begin then (x=0),it's not right!

    this is my decoder link set:

    if(gVdecModuleContext.vdecConfig.decChannelParams[num].isCodec == VDEC_CHN_H264)
    pDecPrm->chCreateParams[num].format = IVIDEO_H264HP;
    else if(gVdecModuleContext.vdecConfig.decChannelParams[num].isCodec == VDEC_CHN_MPEG4)
    pDecPrm->chCreateParams[num].format = IVIDEO_MPEG4ASP;
    else if(gVdecModuleContext.vdecConfig.decChannelParams[num].isCodec == VDEC_CHN_MJPEG)
    pDecPrm->chCreateParams[num].format = IVIDEO_MJPEG;
    pDecPrm->chCreateParams[num].profile = IH264VDEC_PROFILE_ANY;
    pDecPrm->chCreateParams[num].targetMaxWidth = 1920;
    pDecPrm->chCreateParams[num].targetMaxHeight = 1080;
    pDecPrm->chCreateParams[num].displayDelay = 4;
    pDecPrm->chCreateParams[num].processCallLevel = VDEC_FRAMELEVELPROCESSCALL;
    pDecPrm->chCreateParams[num].numBufPerCh = 8;/*Auto*/
    pDecPrm->chCreateParams[num].defaultDynamicParams.targetBitRate = 2*1000*1000;

    every decoder channel use the same set

  • Try setting swmsCreatePrm.outputBufModified to TRUE so that DMA copy from input to output is disabled.

    Decoder output frame startX ,startY for H264 will be 32,24 not 0,0. You have to consider that when setting the OSD coordinate.

  • Hi:

     thanks for your quick reply, the osd display position have solved.

    but the isuude  of display osd still have,  I already try set swmsCreatePrm outputBufModified =TRUE.

    my link chain:   (socket recv)-->ipcbitsOutA8--->ipcbitsInM3video--->dec---->ipcOutM3Video--->ipcInM3vpss-->ipcframeOutVpss-------{process link: ipcframeInDsp--->dsp_alg}--------->swms---->display

    this link chain is my project use(decoder device)

    there are a special issue:

         1. when the program start,the first time decode 704x576, osd display good,then decode 1024x768 ,osd also display good

          2.when the program start,if first decode 1024x768,osd display abnormal,like the video1,then decode 704x576 also abnomal