![Texas Instruments DM365 User Manual Download Page 37](http://html.mh-extra.com/html/texas-instruments/dm365/dm365_user-manual_1094517037.webp)
Sample Usage
3-3
The test application is divided into four logical blocks:
Parameter
setup
Algorithm instance creation and initialization
Process
call
Algorithm instance deletion
3.1.1 Parameter
Setup
Each codec component requires various codec configuration parameters to
be set at initialization. For example, a video codec requires parameters
such as video height, video width, and so on. The test application obtains
the required parameters from the Encoder configuration files.
In this logical block, the test application does the following:
1) Opens the generic configuration file, testvecs.cfg and reads the list of
Encoder configuration file name (testparams.cfg).
2) Opens the Encoder configuration file, (testparams.cfg) and reads the
various configuration parameters required for the algorithm.
For more details on the configuration files, see Section 2.4.
3) Sets
the
IVIDENC1_Params
structure based on the values it reads
from the Testparams.cfg file.
4) Sets the extended parameters of the
IH264VENC_Params
structure
based on the values it reads from the testparams.cfg file.
After successful completion of the above steps, the test application does
the algorithm instance creation and initialization.
3.1.2 Algorithm Instance Creation and Initialization
In this logical block, the test application accepts the various initialization
parameters and returns an algorithm instance pointer. The following APIs
are called in a sequence:
1)
algNumAlloc()
- To query the algorithm about the number of
memory records it requires.
2)
algAlloc()
- To query the algorithm about the memory requirement
to be filled in the memory records.
3)
algInit()
- To initialize the algorithm with the memory structures
provided by the application.
A sample implementation of the create function that calls
algNumAlloc()
,
algAlloc()
, and
algInit()
in sequence is provided
in the
ALG_create()
function implemented in the alg_create.c file.
After successful creation of the algorithm instance, the test application
does DMA resource allocation for the algorithm.
Summary of Contents for DM365
Page 10: ...x This page is intentionally left blank ...
Page 12: ...xii This page is intentionally left blank ...
Page 24: ...Introduction 1 12 This page is intentionally left blank ...
Page 34: ...Installation Overview 2 10 This page is intentionally left blank ...
Page 116: ...API Reference 4 70 This page is intentionally left blank ...
Page 120: ...Error Description B 2 This page is intentionally left blank ...
Page 124: ...ARM926 TCM Buffer Usage By Codec D 2 This page is intentionally left blank ...
Page 126: ...Simple Two pass Encoding Sample Usage E 2 Case 1 Case 2 Case 3 Case 4 Frame Skip ...
Page 130: ...Simple Two pass Encoding Sample Usage E 6 This page is intentionally left blank ...