This section contains APIs to use OpenMAX CODEC Pipelines within demos.
◆ appOMXInit()
Launches the OMXPipeline described by user defined parameters.
- Parameters
-
◆ appOMXEncInit()
int32_t appOMXEncInit |
( |
void * |
data_ptr[CODEC_MAX_BUFFER_DEPTH][CODEC_MAX_NUM_CHANNELS][CODEC_MAX_NUM_PLANES] | ) |
|
Initializes the Encode elements to be able to push buffers to the OMXPipeline. Wraps the given allocated memory as OMXBuffers to push. The input parameters (in_*) must be properly initialised.
- Parameters
-
[in] | data_ptr | memory that the OMXBuffers will map to |
◆ appOMXDecInit()
int32_t appOMXDecInit |
( |
void *(*) |
data_ptr[CODEC_MAX_NUM_CHANNELS][CODEC_MAX_NUM_PLANES] | ) |
|
Initializes the Decode elements to be able to pull buffers from the OMXPipeline. Registers the data_pointers that will map to the bufferpool of pulled OMXBuffers. The output parameters (out_*) must be properly initialised.
- Parameters
-
[in] | data_ptr | pointers to hold the pulled buffers |
◆ appOMXStart()
Starts the OMXPipeline that was launched previously.
◆ appOMXEnqAppEnc()
int32_t appOMXEnqAppEnc |
( |
uint8_t |
idx | ) |
|
Push a buffer from the bufferpool to the Encode element.
- Parameters
-
[in] | idx | the buffer id, from the bufferpool, to be pushed to the OMXPipeline |
◆ appOMXDeqAppEnc()
int32_t appOMXDeqAppEnc |
( |
uint8_t |
idx | ) |
|
Wait for a previously pushed buffer to be consumed by the OMXPipeline.
- Parameters
-
[in] | idx | the buffer id, from the bufferpool, to wait on |
◆ appOMXEnqEosAppEnc()
int32_t appOMXEnqEosAppEnc |
( |
| ) |
|
Push EOS (End Of Stream) to the Encode element. Signals the elements to stop processing buffers after this.
◆ appOMXDeqAppDec()
int32_t appOMXDeqAppDec |
( |
uint8_t |
idx | ) |
|
Pull a buffer from the Decode element into the bufferpool.
- Parameters
-
[in] | idx | the slot into which the pulled data is stored
in the pulled_data_ptr array, while maintaining a reference to the pulled OMXBuffer |
◆ appOMXEnqAppDec()
int32_t appOMXEnqAppDec |
( |
uint8_t |
idx | ) |
|
Release a previously pulled OMXBuffer back to GStreamer and cleanup.
- Parameters
-
[in] | idx | the slot from which the buffer is released back to OMXreamer. The data pointer for this slot is no longer valid |
◆ appOMXStop()
Stops the OMXPipeline that was in playing state. If there is no Decode element, waits to recieve EOS before cleaning up.
◆ appOMXDeInit()
Unmaps all buffers that were mapped and destroys all GStreamer objects.
◆ appOMXPrintStats()
void appOMXPrintStats |
( |
| ) |
|
Prints the current count of the numbers of buffers pushed/pulled to/from the OMXPipeline. Not multi-thread safe.