OpenMAXBellagio 0.9.3
omx_clocksrc_component.h
Go to the documentation of this file.
00001 
00027 #ifndef _OMX_CLOCKSRC_COMPONENT_H_
00028 #define _OMX_CLOCKSRC_COMPONENT_H_
00029 
00030 #include <OMX_Types.h>
00031 #include <OMX_Component.h>
00032 #include <OMX_Core.h>
00033 #include <OMX_Audio.h>
00034 #include <omx_base_source.h>
00035 #include <string.h>
00036 #include <sys/time.h>
00037 
00038 #define CLOCK_COMP_NAME "OMX.st.clocksrc"
00039 #define CLOCK_COMP_ROLE "clocksrc"
00040 #define MAX_CLOCK_COMPONENTS 20
00041 
00043 #define MAX_CLOCK_PORTS                          8
00044 
00045 
00058 DERIVEDCLASS(omx_clocksrc_component_PrivateType, omx_base_source_PrivateType)
00059 #define omx_clocksrc_component_PrivateType_FIELDS omx_base_source_PrivateType_FIELDS \
00060   OMX_TIME_CONFIG_CLOCKSTATETYPE      sClockState; \
00061   OMX_TIME_CONFIG_ACTIVEREFCLOCKTYPE  sRefClock; \
00062   tsem_t*                             startTimeSem; \
00063   tsem_t*                             clockEventSem; \
00064   tsem_t*                             clockEventCompleteSem; \
00065   OMX_TICKS                           WallTimeBase; \
00066   OMX_TICKS                           MediaTimeBase; \
00067   OMX_TIME_UPDATETYPE                 eUpdateType; \
00068   OMX_TIME_CONFIG_TIMESTAMPTYPE       sMinStartTime; \
00069   OMX_TIME_CONFIG_SCALETYPE           sConfigScale;
00070 ENDCLASS(omx_clocksrc_component_PrivateType)
00071 
00072 /* Component private entry points declaration */
00073 OMX_ERRORTYPE omx_clocksrc_component_Constructor(OMX_COMPONENTTYPE *openmaxStandComp,OMX_STRING cComponentName);
00074 OMX_ERRORTYPE omx_clocksrc_component_Destructor(OMX_COMPONENTTYPE *openmaxStandComp);
00075 
00076 void omx_clocksrc_component_BufferMgmtCallback(
00077   OMX_COMPONENTTYPE *openmaxStandComp,
00078   OMX_BUFFERHEADERTYPE* inputbuffer);
00079 
00080 OMX_ERRORTYPE omx_clocksrc_component_GetParameter(
00081   OMX_HANDLETYPE hComponent,
00082   OMX_INDEXTYPE nParamIndex,
00083   OMX_PTR ComponentParameterStructure);
00084 
00085 OMX_ERRORTYPE omx_clocksrc_component_SetParameter(
00086   OMX_HANDLETYPE hComponent,
00087   OMX_INDEXTYPE nParamIndex,
00088   OMX_PTR ComponentParameterStructure);
00089 
00090 OMX_ERRORTYPE omx_clocksrc_component_SetConfig(
00091   OMX_HANDLETYPE hComponent,
00092   OMX_INDEXTYPE nIndex,
00093   OMX_PTR pComponentConfigStructure);
00094 
00095 OMX_ERRORTYPE omx_clocksrc_component_GetConfig(
00096   OMX_HANDLETYPE hComponent,
00097   OMX_INDEXTYPE nIndex,
00098   OMX_PTR pComponentConfigStructure);
00099 
00100 void* omx_clocksrc_BufferMgmtFunction (void* param);
00101 
00102 OMX_ERRORTYPE omx_clocksrc_component_SendCommand(
00103   OMX_HANDLETYPE hComponent,
00104   OMX_COMMANDTYPE Cmd,
00105   OMX_U32 nParam,
00106   OMX_PTR pCmdData);
00107 
00108 OMX_ERRORTYPE clocksrc_port_FlushProcessingBuffers(omx_base_PortType *openmaxStandPort);
00109 
00110 #endif