OpenMAX Bellagio 0.9.3
|
Data Structures | |
struct | OMX_BUFFERHEADERTYPE |
Macros | |
#define | OMX_BUFFERFLAG_EOS 0x00000001 |
#define | OMX_BUFFERFLAG_STARTTIME 0x00000002 |
#define | OMX_BUFFERFLAG_DECODEONLY 0x00000004 |
#define | OMX_BUFFERFLAG_CODECCONFIG 0x00000080 |
#define | OMX_UseBuffer( hComponent, ppBufferHdr, nPortIndex, pAppPrivate, nSizeBytes, pBuffer) |
#define | OMX_AllocateBuffer( hComponent, ppBuffer, nPortIndex, pAppPrivate, nSizeBytes) |
#define | OMX_FreeBuffer( hComponent, nPortIndex, pBuffer) |
#define | OMX_EmptyThisBuffer( hComponent, pBuffer) |
#define | OMX_FillThisBuffer( hComponent, pBuffer) |
#define | OMX_UseEGLImage( hComponent, ppBufferHdr, nPortIndex, pAppPrivate, eglImage) |
Typedefs | |
typedef struct OMX_BUFFERHEADERTYPE | OMX_BUFFERHEADERTYPE |
typedef enum OMX_BUFFERSUPPLIERTYPE | OMX_BUFFERSUPPLIERTYPE |
Enumerations | |
enum | OMX_BUFFERSUPPLIERTYPE { OMX_BufferSupplyUnspecified = 0x0 , OMX_BufferSupplyInput , OMX_BufferSupplyOutput , OMX_BufferSupplyKhronosExtensions = 0x6F000000 , OMX_BufferSupplyVendorStartUnused = 0x7F000000 , OMX_BufferSupplyMax = 0x7FFFFFFF } |
Buffer handling functions and structures
#define OMX_AllocateBuffer | ( | hComponent, | |
ppBuffer, | |||
nPortIndex, | |||
pAppPrivate, | |||
nSizeBytes ) |
The OMX_AllocateBuffer macro will request that the component allocate a new buffer and buffer header. The component will allocate the buffer and the buffer header and return a pointer to the buffer header. This is a blocking call.
The component should return from this call within 5 msec.
[in] | hComponent | Handle of the component to be accessed. This is the component handle returned by the call to the OMX_GetHandle function. |
[out] | ppBuffer | pointer to an OMX_BUFFERHEADERTYPE structure used to receive the pointer to the buffer header |
[in] | nPortIndex | nPortIndex is used to select the port on the component the buffer will be used with. The port can be found by using the nPortIndex value as an index into the Port Definition array of the component. |
[in] | pAppPrivate | pAppPrivate is used to initialize the pAppPrivate member of the buffer header structure. |
[in] | nSizeBytes | size of the buffer to allocate. Used when bAllocateNew is true. |
Definition at line 1028 of file OMX_Core.h.
Referenced by main().
#define OMX_BUFFERFLAG_CODECCONFIG 0x00000080 |
Codec Config Buffer Flag: OMX_BUFFERFLAG_CODECCONFIG is an optional flag that is set by an output port when all bytes in the buffer form part or all of a set of codec specific configuration data. Examples include SPS/PPS nal units for OMX_VIDEO_CodingAVC or AudioSpecificConfig data for OMX_AUDIO_CodingAAC. Any component that for a given stream sets OMX_BUFFERFLAG_CODECCONFIG shall not mix codec configuration bytes with frame data in the same buffer, and shall send all buffers containing codec configuration bytes before any buffers containing frame data that those configurations bytes describe. If the stream format for a particular codec has a frame specific header at the start of each frame, for example OMX_AUDIO_CodingMP3 or OMX_AUDIO_CodingAAC in ADTS mode, then these shall be presented as normal without setting OMX_BUFFERFLAG_CODECCONFIG.
Definition at line 393 of file OMX_Core.h.
#define OMX_BUFFERFLAG_DECODEONLY 0x00000004 |
Decode Only Buffer Flag:
The source of a stream (e.g. a demux component) sets the DECODEONLY flag on any buffer that should shall be decoded but should not be displayed. This flag is used, for instance, when a source seeks to a target interframe that requires the decode of frames preceding the target to facilitate the target's reconstruction. In this case the source would emit the frames preceding the target downstream but mark them as decode only.
The DECODEONLY is associated with buffer data and propagated in a manner identical to the buffer timestamp.
A component that renders data should ignore all buffers with the DECODEONLY flag set.
Definition at line 349 of file OMX_Core.h.
#define OMX_BUFFERFLAG_EOS 0x00000001 |
End of Stream Buffer Flag:
A component sets EOS when it has no more data to emit on a particular output port. Thus an output port shall set EOS on the last buffer it emits. A component's determination of when an output port should cease sending data is implemenation specific.
Definition at line 299 of file OMX_Core.h.
Referenced by audiomixerEmptyBufferDone(), audiomixerEventHandler(), omx_audio_mixer_BufferMgmtFunction(), omx_base_filter_BufferMgmtFunction(), omx_base_sink_BufferMgmtFunction(), omx_base_sink_twoport_BufferMgmtFunction(), omx_base_source_BufferMgmtFunction(), omx_base_source_twoport_BufferMgmtFunction(), omx_video_scheduler_component_BufferMgmtCallback(), omx_video_scheduler_component_port_SendBufferFunction(), volcEmptyBufferDone(), and volcEventHandler().
#define OMX_BUFFERFLAG_STARTTIME 0x00000002 |
Start Time Buffer Flag:
The source of a stream (e.g. a demux component) sets the STARTTIME flag on the buffer that contains the starting timestamp for the stream. The starting timestamp corresponds to the first data that should be displayed at startup or after a seek. The first timestamp of the stream is not necessarily the start time. For instance, in the case of a seek to a particular video frame, the target frame may be an interframe. Thus the first buffer of the stream will be the intra-frame preceding the target frame and the starttime will occur with the target frame (with any other required frames required to reconstruct the target intervening).
The STARTTIME flag is directly associated with the buffer's timestamp ' thus its association to buffer data and its propagation is identical to the timestamp's.
When a Sync Component client receives a buffer with the STARTTIME flag it shall perform a SetConfig on its sync port using OMX_ConfigTimeClientStartTime and passing the buffer's timestamp.
Definition at line 326 of file OMX_Core.h.
Referenced by omx_base_filter_BufferMgmtFunction(), and omx_video_scheduler_component_ClockPortHandleFunction().
#define OMX_EmptyThisBuffer | ( | hComponent, | |
pBuffer ) |
The OMX_EmptyThisBuffer macro will send a buffer full of data to an input port of a component. The buffer will be emptied by the component and returned to the application via the EmptyBufferDone call back. This is a non-blocking call in that the component will record the buffer and return immediately and then empty the buffer, later, at the proper time. As expected, this macro may be invoked only while the component is in the OMX_StateExecuting. If nPortIndex does not specify an input port, the component shall return an error.
The component should return from this call within 5 msec.
[in] | hComponent | Handle of the component to be accessed. This is the component handle returned by the call to the OMX_GetHandle function. |
[in] | pBuffer | pointer to an OMX_BUFFERHEADERTYPE structure allocated with UseBuffer or AllocateBuffer. |
Definition at line 1096 of file OMX_Core.h.
Referenced by audiomixerEmptyBufferDone(), main(), and volcEmptyBufferDone().
#define OMX_FillThisBuffer | ( | hComponent, | |
pBuffer ) |
The OMX_FillThisBuffer macro will send an empty buffer to an output port of a component. The buffer will be filled by the component and returned to the application via the FillBufferDone call back. This is a non-blocking call in that the component will record the buffer and return immediately and then fill the buffer, later, at the proper time. As expected, this macro may be invoked only while the component is in the OMX_ExecutingState. If nPortIndex does not specify an output port, the component shall return an error.
The component should return from this call within 5 msec.
[in] | hComponent | Handle of the component to be accessed. This is the component handle returned by the call to the OMX_GetHandle function. |
[in] | pBuffer | pointer to an OMX_BUFFERHEADERTYPE structure allocated with UseBuffer or AllocateBuffer. |
Definition at line 1126 of file OMX_Core.h.
Referenced by audiomixerFillBufferDone(), main(), and volcFillBufferDone().
#define OMX_FreeBuffer | ( | hComponent, | |
nPortIndex, | |||
pBuffer ) |
The OMX_FreeBuffer macro will release a buffer header from the component which was allocated using either OMX_AllocateBuffer or OMX_UseBuffer. If
the component allocated the buffer (see the OMX_UseBuffer macro) then the component shall free the buffer and buffer header. This is a blocking call.
The component should return from this call within 20 msec.
[in] | hComponent | Handle of the component to be accessed. This is the component handle returned by the call to the OMX_GetHandle function. |
[in] | nPortIndex | nPortIndex is used to select the port on the component the buffer will be used with. |
[in] | pBuffer | pointer to an OMX_BUFFERHEADERTYPE structure allocated with UseBuffer or AllocateBuffer. |
Definition at line 1064 of file OMX_Core.h.
Referenced by base_port_FreeTunnelBuffer(), and main().
#define OMX_UseBuffer | ( | hComponent, | |
ppBufferHdr, | |||
nPortIndex, | |||
pAppPrivate, | |||
nSizeBytes, | |||
pBuffer ) |
The OMX_UseBuffer macro will request that the component use a buffer (and allocate its own buffer header) already allocated by another component, or by the IL Client. This is a blocking call.
The component should return from this call within 20 msec.
[in] | hComponent | Handle of the component to be accessed. This is the component handle returned by the call to the OMX_GetHandle function. |
[out] | ppBuffer | pointer to an OMX_BUFFERHEADERTYPE structure used to receive the pointer to the buffer header |
Definition at line 985 of file OMX_Core.h.
Referenced by base_port_AllocateTunnelBuffer().
#define OMX_UseEGLImage | ( | hComponent, | |
ppBufferHdr, | |||
nPortIndex, | |||
pAppPrivate, | |||
eglImage ) |
The OMX_UseEGLImage macro will request that the component use a EGLImage provided by EGL (and allocate its own buffer header) This is a blocking call.
The component should return from this call within 20 msec.
[in] | hComponent | Handle of the component to be accessed. This is the component handle returned by the call to the OMX_GetHandle function. |
[out] | ppBuffer | pointer to an OMX_BUFFERHEADERTYPE structure used to receive the pointer to the buffer header. Note that the memory location used for this buffer is NOT visible to the IL Client. |
[in] | nPortIndex | nPortIndex is used to select the port on the component the buffer will be used with. The port can be found by using the nPortIndex value as an index into the Port Definition array of the component. |
[in] | pAppPrivate | pAppPrivate is used to initialize the pAppPrivate member of the buffer header structure. |
[in] | eglImage | eglImage contains the handle of the EGLImage to use as a buffer on the specified port. The component is expected to validate properties of the EGLImage against the configuration of the port to ensure the component can use the EGLImage as a buffer. |
Definition at line 1165 of file OMX_Core.h.
typedef struct OMX_BUFFERHEADERTYPE OMX_BUFFERHEADERTYPE |
typedef enum OMX_BUFFERSUPPLIERTYPE OMX_BUFFERSUPPLIERTYPE |
The OMX_BUFFERSUPPLIERTYPE enumeration is used to dictate port supplier preference when tunneling between two ports.
The OMX_BUFFERSUPPLIERTYPE enumeration is used to dictate port supplier preference when tunneling between two ports.
Definition at line 600 of file OMX_Core.h.
OMX_ERRORTYPE(* OMX_COMPONENTTYPE::AllocateBuffer) (OMX_HANDLETYPE hComponent, OMX_BUFFERHEADERTYPE **ppBuffer, OMX_U32 nPortIndex, OMX_PTR pAppPrivate, OMX_U32 nSizeBytes) |
refer to OMX_AllocateBuffer in OMX_core.h or the OMX IL specification for details on the AllocateBuffer method.
Definition at line 490 of file OMX_Component.h.
Referenced by omx_base_component_Constructor().
OMX_ERRORTYPE(* OMX_CALLBACKTYPE::EmptyBufferDone) (OMX_HANDLETYPE hComponent, OMX_PTR pAppData, OMX_BUFFERHEADERTYPE *pBuffer) |
The EmptyBufferDone method is used to return emptied buffers from an input port back to the application for reuse. This is a blocking call so the application should not attempt to refill the buffers during this call, but should queue them and refill them in another thread. There is no error return, so the application shall handle any errors generated internally.
The application should return from this call within 5 msec.
hComponent | handle of the component to access. This is the component handle returned by the call to the GetHandle function. |
pAppData | pointer to an application defined value that was provided in the pAppData parameter to the OMX_GetHandle method for the component. This application defined value is provided so that the application can have a component specific context when receiving the callback. |
pBuffer | pointer to an OMX_BUFFERHEADERTYPE structure allocated with UseBuffer or AllocateBuffer indicating the buffer that was emptied. |
Definition at line 560 of file OMX_Core.h.
Referenced by omx_base_component_SetCallbacks().
OMX_ERRORTYPE(* OMX_COMPONENTTYPE::EmptyThisBuffer) (OMX_HANDLETYPE hComponent, OMX_BUFFERHEADERTYPE *pBuffer) |
refer to OMX_EmptyThisBuffer in OMX_core.h or the OMX IL specification for details on the EmptyThisBuffer method.
Definition at line 510 of file OMX_Component.h.
Referenced by omx_base_component_Constructor().
OMX_ERRORTYPE(* OMX_CALLBACKTYPE::FillBufferDone) (OMX_HANDLETYPE hComponent, OMX_PTR pAppData, OMX_BUFFERHEADERTYPE *pBuffer) |
The FillBufferDone method is used to return filled buffers from an output port back to the application for emptying and then reuse.
This is a blocking call so the application should not attempt to empty the buffers during this call, but should queue the buffers and empty them in another thread. There is no error return, so the application shall handle any errors generated internally. The application shall also update the buffer header to indicate the number of bytes placed into the buffer.
The application should return from this call within 5 msec.
hComponent | handle of the component to access. This is the component handle returned by the call to the GetHandle function. |
pAppData | pointer to an application defined value that was provided in the pAppData parameter to the OMX_GetHandle method for the component. This application defined value is provided so that the application can have a component specific context when receiving the callback. |
pBuffer | pointer to an OMX_BUFFERHEADERTYPE structure allocated with UseBuffer or AllocateBuffer indicating the buffer that was filled. |
Definition at line 589 of file OMX_Core.h.
Referenced by omx_base_component_SetCallbacks().
OMX_ERRORTYPE(* OMX_COMPONENTTYPE::FillThisBuffer) (OMX_HANDLETYPE hComponent, OMX_BUFFERHEADERTYPE *pBuffer) |
refer to OMX_FillThisBuffer in OMX_core.h or the OMX IL specification for details on the FillThisBuffer method.
Definition at line 518 of file OMX_Component.h.
Referenced by omx_base_component_Constructor().
OMX_ERRORTYPE(* OMX_COMPONENTTYPE::FreeBuffer) (OMX_HANDLETYPE hComponent, OMX_U32 nPortIndex, OMX_BUFFERHEADERTYPE *pBuffer) |
refer to OMX_FreeBuffer in OMX_core.h or the OMX IL specification for details on the FreeBuffer method.
Definition at line 501 of file OMX_Component.h.
Referenced by omx_base_component_Constructor().
OMX_ERRORTYPE(* OMX_COMPONENTTYPE::UseBuffer) (OMX_HANDLETYPE hComponent, OMX_BUFFERHEADERTYPE **ppBufferHdr, OMX_U32 nPortIndex, OMX_PTR pAppPrivate, OMX_U32 nSizeBytes, OMX_U8 *pBuffer) |
refer to OMX_UseBuffer in OMX_core.h or the OMX IL specification for details on the UseBuffer method.
Definition at line 478 of file OMX_Component.h.
Referenced by omx_base_component_Constructor().
OMX_ERRORTYPE(* OMX_COMPONENTTYPE::UseEGLImage) (OMX_HANDLETYPE hComponent, OMX_BUFFERHEADERTYPE **ppBufferHdr, OMX_U32 nPortIndex, OMX_PTR pAppPrivate, void *eglImage) |
Definition at line 560 of file OMX_Component.h.
Referenced by omx_base_component_Constructor().