00001
00031 #ifndef _OMX_PARSER_3GP_COMPONENT_H_
00032 #define _OMX_PARSER_3GP_COMPONENT_H_
00033
00034 #ifdef HAVE_CONFIG_H
00035 #include "config.h"
00036 #endif
00037
00038 #include <OMX_Types.h>
00039 #include <OMX_Component.h>
00040 #include <OMX_Core.h>
00041 #include <omx_base_source.h>
00042 #include <string.h>
00043
00044
00045 #if FFMPEG_LIBNAME_HEADERS
00046 #include <libavcodec/avcodec.h>
00047 #include <libavformat/avformat.h>
00048 #include <libavformat/avio.h>
00049 #else
00050
00051 #include <ffmpeg/avcodec.h>
00052 #include <ffmpeg/avformat.h>
00053 #include <ffmpeg/avio.h>
00054 #endif
00055
00057 #define MAX_NUM_OF_parser3gp_component_INSTANCES 1
00058
00074 DERIVEDCLASS(omx_parser3gp_component_PrivateType, omx_base_source_PrivateType)
00075 #define omx_parser3gp_component_PrivateType_FIELDS omx_base_source_PrivateType_FIELDS \
00076 OMX_TIME_CONFIG_TIMESTAMPTYPE sTimeStamp; \
00077 AVFormatContext *avformatcontext; \
00078 AVFormatParameters *avformatparameters; \
00079 AVInputFormat *avinputformat; \
00080 OMX_BUFFERHEADERTYPE* pTmpOutputBuffer; \
00081 OMX_STRING sInputFileName; \
00082 OMX_U32 video_coding_type; \
00083 OMX_U32 audio_coding_type; \
00084 tsem_t* avformatSyncSem; \
00085 OMX_BOOL avformatReady; \
00086 OMX_S32 xScale; \
00087 AVPacket pkt;
00088 ENDCLASS(omx_parser3gp_component_PrivateType)
00089
00090
00091 OMX_ERRORTYPE omx_parser3gp_component_Constructor(OMX_COMPONENTTYPE *openmaxStandComp,OMX_STRING cComponentName);
00092 OMX_ERRORTYPE omx_parser3gp_component_Destructor(OMX_COMPONENTTYPE *openmaxStandComp);
00093 OMX_ERRORTYPE omx_parser3gp_component_MessageHandler(OMX_COMPONENTTYPE*,internalRequestMessageType*);
00094 OMX_ERRORTYPE omx_parser3gp_component_Init(OMX_COMPONENTTYPE *openmaxStandComp);
00095 OMX_ERRORTYPE omx_parser3gp_component_Deinit(OMX_COMPONENTTYPE *openmaxStandComp);
00096
00097 void omx_parser3gp_component_BufferMgmtCallback(
00098 OMX_COMPONENTTYPE *openmaxStandComp,
00099 OMX_BUFFERHEADERTYPE* outputbuffer);
00100
00101 OMX_ERRORTYPE omx_parser3gp_component_GetParameter(
00102 OMX_IN OMX_HANDLETYPE hComponent,
00103 OMX_IN OMX_INDEXTYPE nParamIndex,
00104 OMX_INOUT OMX_PTR ComponentParameterStructure);
00105
00106 OMX_ERRORTYPE omx_parser3gp_component_SetParameter(
00107 OMX_IN OMX_HANDLETYPE hComponent,
00108 OMX_IN OMX_INDEXTYPE nParamIndex,
00109 OMX_IN OMX_PTR ComponentParameterStructure);
00110
00111 OMX_ERRORTYPE omx_parser3gp_component_SetConfig(
00112 OMX_IN OMX_HANDLETYPE hComponent,
00113 OMX_IN OMX_INDEXTYPE nIndex,
00114 OMX_IN OMX_PTR pComponentConfigStructure);
00115
00116 OMX_ERRORTYPE omx_parser3gp_component_GetConfig(
00117 OMX_IN OMX_HANDLETYPE hComponent,
00118 OMX_IN OMX_INDEXTYPE nIndex,
00119 OMX_IN OMX_PTR pComponentConfigStructure);
00120
00121 OMX_ERRORTYPE omx_parser3gp_component_GetExtensionIndex(
00122 OMX_IN OMX_HANDLETYPE hComponent,
00123 OMX_IN OMX_STRING cParameterName,
00124 OMX_OUT OMX_INDEXTYPE* pIndexType);
00125
00126 #endif
00127