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.

OMTB: getparam command

Guru 10685 points

I'm getting into the OpenMAX Test Bench application provided on the latest EZSDK (5.01.01.80) and experiencing some confusion. My 2 questions are:

1) When you use "gethandle" to make a component instance take on the values that were setup in a template, do the parameter values get copied across to the newly instantiated component or is it just a link?

2) Why does the "getparam" command need to be passed a template number? Surely the whole point of templates are that a component instance can only have one set of parameter values at a time, and those parameter values would have been setup previously using a "gethandle" command to copy the parameter values from a template to a component instance in a one-off procedure?

3) Does OMTB support multiple instances of the H264 decoder?

Thanks,
Ralph

  •  

    1) The initial parameter values which are set before calling gethandle are passed as input when creating the OMX component.  The component is then initialized with these values.

    2) The getparam is called to get the default parameter value for the component instance.  Afterwards a particular parameter is modified thus overriding the default value and updating the template.  

    3) Multiple instances of the H.264 decoder is support (up to 2 for this release)

  • 2) Surely you mean the current parameter value is copied into a template for you to modify so that the modfied template can then be used to set the values in a component instance? What would be the point in getting the default value when you already have this stored in the template?

    I think this has become clearer to me since first posting but I'd be grateful if you could confirm what I've said above (though it seems to not be _exactly_ the same as what you've just said).

    Thanks,

    Ralph

  • Hi, is there any answer forthcoming regarding this question?

    _Ralph_ said:

    2) Surely you mean the current parameter value is copied into a template for you to modify so that the modfied template can then be used to set the values in a component instance? What would be the point in getting the default value when you already have this stored in the template?

    I think this has become clearer to me since first posting but I'd be grateful if you could confirm what I've said above (though it seems to not be _exactly_ the same as what you've just said).

    Thanks a lot,

    Ralph

  • I said getparams is used to get the "default parameter values".  Instead, I should have said "current parameter value"

  • Hi Marcus,

    thanks for confirming that.

    I have modified the "decode_scale_display.oms" script in order to perform dual decode.

    In summary, here is what I did to create the script:

    • duplicated the existing code (with some reordering so that components for each video were kept in similar states as the script progressed)
    • changed the nDrvInstID (so the second video would be displayed on the analogue DAC output)
    • changed the component template numbers (to avoid any complexity I used a new template for the second video)
    • changed the component instance numbers (obviously)

    Everything else is the same between video parameters. I attach the script to this post.

    Despite all this, the code hangs when I try to put the second video decoder into IDLE state. This is the last line of output from the script: I also attach the debug output to this post.

    OMTB> omx api sendcommand state h264vdec 1 idle
    OMTB-OMX_ErrorNone

    Please could you help me get this working? I cannot understand why it isn't. The normal "decode_scale_display.oms" script works fine. :-/

    Thanks,

    Ralph

    1614.Desktop.zip

  • I've found a bit in the user guide that states "Current  release  only  supports  one  video  decoder  and  one video encoder components so multiple codec options will not be displayed." so I suppose this is solved. Still, it would be interesting to know the background reason for this.

    Ralph

  • Hi Guys

    Can I instantiate 2 Decoders using the OMX.TI.DUCATI.VIDDEC in code by caling Get handle in seperate threads. I want to decode 2 seperate file streams and display them on separate Output?. Is it the same for the scalar and VENC etc?

    How do I call them? At the moment It returns the same handle for both calls

    Robin