Public Attributes

limoi_component_callbacks_t Struct Reference
[limoi base core]

#include <limoi-component.h>

List of all members.

Public Attributes

OMX_ERRORTYPE(* command_prep )(limoi_component_cmd_t *cmd)
OMX_ERRORTYPE(* command_post )(limoi_component_cmd_t *cmd)
OMX_ERRORTYPE(* main )(OMX_HANDLETYPE hComp, limoi_port_t **audio_port, limoi_port_t **video_port, limoi_port_t **other_port, int *preloaded)
OMX_ERRORTYPE(* sub )(OMX_HANDLETYPE hComp, limoi_port_t **audio_port, limoi_port_t **video_port, limoi_port_t **other_port)

Detailed Description

limoi base component callbacks. while 'command' and 'sub' callbacks are optional, 'main' callback is mandatory. For asynchronous component, each type of callback is carried out in its own thread.


Member Data Documentation

OMX_ERRORTYPE(* command_post)(limoi_component_cmd_t *cmd)

component private command post process handle. if not null, this gets called after the core processes command within the callback context, without holding the command mutex, nor the component and port mutex.

OMX_ERRORTYPE(* command_prep)(limoi_component_cmd_t *cmd)

component private command preparation handle. if not null, this gets called before the core processes command within the callback context, without holding the command mutex, nor the component and port mutex.

OMX_ERRORTYPE(* main)(OMX_HANDLETYPE hComp, limoi_port_t **audio_port, limoi_port_t **video_port, limoi_port_t **other_port, int *preloaded)

component main data processing handle. this gets called without holding any mutex, when component is in executing state, or pause state before preload is completed, where the component completes its data processing.

callback shall return upon completing of each port buffer, thus giving the underlying system the opportunity to respond to state transition request.

callback usually should not block other than on starving of port buffers, if it blocks otherwise, sub-class implementor must provide mechanism to unblock upon state transition from executing/pause to idle, or any port disable command.

if callback returns any value otherthan OMX_ErrorNone, component will wait for base->cond for a bit before retry. To exit main thread, client has to explicitly request a state transition.

OMX_ERRORTYPE(* sub)(OMX_HANDLETYPE hComp, limoi_port_t **audio_port, limoi_port_t **video_port, limoi_port_t **other_port)

component supplementory data processing handle. this gets called without holding any mutex, when component is in executing state.

the main interest of this thread shall be 'other_port', so that component can process supplementory data asynchronously, to respond to clock update as an example.

if callback returns any value otherthan OMX_ErrorNone, component will wait for base->cond for a bit before retry, except that if callback returns OMX_ErrorNoMore, sub thread will be automatically shutdown.

LIMOpenMAX Implementation API Reference - Generated by doxygen