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.

Questions about libraries and test codes

Other Parts Discussed in Thread: OMAP3530

I've played with DVSDK for some time now, and also read some documents. But I still don't have a big picture of how the whole package is organized, especially I have the following questions:

1. About libraries: why are there many different libraries? what are they for?

Under dvsdk_3_00_00_29/omap3530_dvsdk_combos_3_16/packages/ti/sdo/codecs, there is a folder for every type of codec, such as h264enc, h264dec, etc. Under each of these folders, there is a sub-folder called lib; in lib, there is a library such as h264vdec_ti_e_l64P. Then under dvsdk_3_00_00_29/omap3530_dvsdk_combos_3_16/packages/ti/sdo/servers/decode, there is big library called decodeCombo.x64P. My understanding is that decodeCombo.x64P is composed of all the l64P libraries. If my application only needs to run H.264 decoder, I can link with h264vdec_ti_e_l64P only; no need for decodeCombo.x64P. Is this correct?

Under dvsdk_3_00_00_29/codec_engine_2_20_01/packages/ti/sdo/ce/lib, there are eight different libraries: ce.a470uC, ce.a64P, ce.a86U, ce.av5T, and their debug versions. Then under dvsdk_3_00_00_29/codec_engine_2_20_01/packages/ti/sdo/ce/video/lib, there are video.a470uC, video.a64P, video.a86U, and video.av5T. There are other, similar folders, such as audio, video2, etc, each with their own libraries. What are these libraries for? Are these libraries the GPP counterparts for the DSP libraries mentioned above? If so, why is there an a64P library?

2. About test codes: why are there many different libraries? what are they for?

There are test codes in dvsdk_3_00_00_29/dvtb_3_00_012; there are some others in dvsdk_3_00_00_29/dmai_1_20_00_04/packages/ti/sdo/dmai/apps, such as audio_decode_io, video_deocde_io2, etc. Of course, there are also examples in dvsdk_3_00_00_29/codec_engine_2_20_01/examples. What purposes do these different test coeds serve? For example, if I want to measure the H.264 decoder performance, which test code(s) would be the most suitable to use?

3. About a specific test code:

If I understand correctly, the test code in dvsdk_3_00_00_29/dmai_1_20_00_04/packages/ti/sdo/dmai/apps/video_deocde_io2/appMain.c uses the timer on the DSP part to perform benchmarking, but the measured results are converted to time (us). Is this correct? If so, is there a way to get the cycle counts?

DVSDK gurus, please share your insights, or guide me to some documents. Thank you very much.

Happy holidays!

  • Hi,

    RobbySun said:

    1. About libraries: why are there many different libraries? what are they for?

    Under dvsdk_3_00_00_29/omap3530_dvsdk_combos_3_16/packages/ti/sdo/codecs, there is a folder for every type of codec, such as h264enc, h264dec, etc. Under each of these folders, there is a sub-folder called lib; in lib, there is a library such as h264vdec_ti_e_l64P. Then under dvsdk_3_00_00_29/omap3530_dvsdk_combos_3_16/packages/ti/sdo/servers/decode, there is big library called decodeCombo.x64P. My understanding is that decodeCombo.x64P is composed of all the l64P libraries. If my application only needs to run H.264 decoder, I can link with h264vdec_ti_e_l64P only; no need for decodeCombo.x64P. Is this correct?

    Under dvsdk_3_00_00_29/codec_engine_2_20_01/packages/ti/sdo/ce/lib, there are eight different libraries: ce.a470uC, ce.a64P, ce.a86U, ce.av5T, and their debug versions. Then under dvsdk_3_00_00_29/codec_engine_2_20_01/packages/ti/sdo/ce/video/lib, there are video.a470uC, video.a64P, video.a86U, and video.av5T. There are other, similar folders, such as audio, video2, etc, each with their own libraries. What are these libraries for? Are these libraries the GPP counterparts for the DSP libraries mentioned above? If so, why is there an a64P library?

    The codecs are packed with TI XDC tools, so to make sense of this tools you should take a look at the XDC documentation to understand the rationale behind. For the first part of your question, I think that you need to use the decodeCombo.x64P (you can't use the specific parts). You see, the DSP binary is a hole, and the libraries are compiled as individual projects but linked together in the final codec server (BTW: as far I understand the decodeCombo server included is for evaluation proposes). If you wan a codec server with h264 only you need to buy a customized codec server from TI or TI ASP.

    The other libraries you are mentioning are the CodecEngine libraries (ce). CodecEngine is the abstraction library that let you use the codecs in a generic way without requiring specific APIS for h264, mpeg4, wma, and even more important to have an standardized interface for all the codecs from the different TI third parties (you can get a h264 codec from A or from B, and they will use the same interface). The CE libraries are not counterparts for the DSP libraries, are the accessors for them from the GPP side. However CodecEngine is also used from multi-DSP-core systems to enable communication between the processors, so CodecEngine can be used as well from the DSP side (thus the reason of having a a64P libraries as well).  XDC packages contains libraries for all the supported targets, that's the reason you see so many targets.

    In the end I think you are better off reading the XDC tools getting started guide, you don't need to worry so much about the internals of the libraries unless you are a XDC developer. XDC provides tools (like configuro) that provides you the linker files that will point to all the required libraries for your specific requirements.

    RobbySun said:

    2. About test codes: why are there many different libraries? what are they for?

    There are test codes in dvsdk_3_00_00_29/dvtb_3_00_012; there are some others in dvsdk_3_00_00_29/dmai_1_20_00_04/packages/ti/sdo/dmai/apps, such as audio_decode_io, video_deocde_io2, etc. Of course, there are also examples in dvsdk_3_00_00_29/codec_engine_2_20_01/examples. What purposes do these different test coeds serve? For example, if I want to measure the H.264 decoder performance, which test code(s) would be the most suitable to use?

    The dvtb, dmai, and codec engine are different packages that serve different proposes, so they have different test suites:

    * DVTB: is a validation tool for the codecs itselfs and their API compliance with CodecEngine (If I recall correctly, but I may be wrong, I have never use it).

    * CodecEngine: is the framework for the codecs, the examples here are used to validate the codec API works as expected.

    * DMAI: is a framework that abstracts certain operations like video capture, video display, encode/decode, memory copy on all the TI Davinci and OMAP 35x family, so the test code here validates this API.

    If you want to measure the H.264 decoder performance, use the decode demo of the DVSDK.

    I'm not an expert on DSP programming (yet), so I don't have an answer for #3.

    Regards and happy holidays,

    Diego Dompe

    RidgeRun Engineering

  • Thank you Diego for the detailed explanation about different libraries; that helps a lot.

    As for the various test suites, I'll play with them more. I guess they probably are for different users, e.g. system integraters, library developers, etc.

    Happy holidays!