libstagefrighthw.so
1,createOMXPlugin
{
1,new SECOMXPlugin;
2,SECOMXPlugin()
{
1,open the libSEC_OMX_Core.so
2,get all interface fun,example for SEC_OMX_Init,SEC_OMX_DeInit,SEC_OMX_DeInit
3,call SEC_OMX_Init
}
}
libSEC_OMX_Core.so
1,SEC_OMX_Init
{
SEC_OMX_Component_Register
{
1,read file of /system/etc/secomxregistry,get componet library name
2,call SEC_OMX_COMPONENT_Library_Register of special component,get all component info and save to global list.
}
}
2,SEC_OMX_GetHandle
{
1,base on the name supplied to look up the component.
2,open the library file whire the component is.
2,call the function SEC_OMX_ComponentInit of the component,return the handle of OMX_COMPONENTTYPE.
4,check if the functions of handle are ok.
5,return handle to hight level
}
libOMX.SEC.AVC.Decoder.so
1,SEC_OMX_COMPONENT_Library_Register
{
componentName is "OMX.SEC.AVC.Decoder"
roles is "video_decoder.avc"
}
//key point
SSBSIP_MFC_ERROR_CODE SsbSipMfcDecExe(void *openHandle, int lengthBufFill)
{
pCTX->displayStatus = 1;//very important for continue display
}
//
SSBSIP_MFC_ERROR_CODE SsbSipMfcDecSetConfig(void *openHandle, SSBSIP_MFC_DEC_CONF conf_type, void *value)
{
case MFC_DEC_SETCONF_FRAME_TAG:
pCTX->in_frametag = *((int *)value);//sync for frame
return MFC_RET_OK;
}
阅读(2861) | 评论(0) | 转发(1) |