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.

how to get extended error codes of h264 decoder when using dmai?

Hello,

I need the extended error codes of the H264 decoder 2.00.00.13. In my application, I use the Vdec2_process() call to decode encoded buffers. But I can't evaluate the extended errors, which are displayed when I call the application with DMAI_DEBUG=2. After the process call, I use Vdec2_getVisaHandle() and then VIDDEC2_control() with XDM_GETSTATUS but the output of the VIDDEC2_Status.extendedError structure is always 0 and not the value which is printed with DMAI_DEBUG=2.

Regards,

Matthias

  • Hi,

    Hope you are refering to  DM36x H264 decoder. extended Error with DMAI debug and extended error with GETSTATUS control call should be same. Same extended parameter ie getting populated in both cases. Is VIDDEC2_control() is returning success?

    Please check parameter passing to control call.

    Thanks,

    Veeranna

  • Hi,

    yes it is the DM36x H264 decoder. It seems that VIDDEC2_control() returns -1. My source code is:

    VIDDEC2_Status    statViddec2;

    Int32                           retControl;

    VIDDEC2_Handle   hViddec2 = NULL;

    ...........................................

    ret = Vdec2_process(hVd2, hInBuf, hDstBuf);

    hViddec2 = Vdec2_getVisaHandle(hVd2);

    retControl = VIDDEC2_control(hViddec2, XDM_GETSTATUS, NULL, &statViddec2);   /* VIDDEC2_control returns always -1 */

    printf("Error code: 0x%x\n", (unsigned int) statViddec2.extendedError);                           /* extendedError is always 0x0 */

    Hopefully this would help.

    Regards,

    Matthias

  • Hi,

    Control call is getting failed it should return '0' or success, thats why extended error is wrong. Please check params passing to control are fine, specially Handle

    Thanks,

    Veeranna

  • Hi,

    it seems that the values of my Vdec2_Handle and my VIDDEC2_Handle are different. But the Vdec2_Handle consists of a VIDDEC2_Handle in first place so it should be the same or not? Is it possible that I have to use the VIDDEC2_Handle OR the Vdec2_Handle for all decoder related functions (i.e. always use the Vdec2_Handle with DMAI functions OR always use the VIDDEC2_Handle with VISA functions)?

    Regards,

    Matthias

  • Hi,

    You are right about usage of handle.

    i.e. always use the Vdec2_Handle with DMAI functions AND always use the VIDDEC2_Handle with VISA functions. VIDDEC2_Handle is part of Vdec2_Handle. DMAI package will have source code release you can have look for more information.

    Looks you are passing correct visa handle to visa control call. And seen you are not setting status size. Please set it to default or extended status size.

    Thanks,

    Veeranna

  • Yes, it seems that I forgot to set the size value of VIDDEC2_Status structure. Now it works fine. Thank you!

    Regards,

    Matthias