return ret;
}
+#ifndef TIZEN_FEATURE_E3250
int Check_H264_Frame(
OMX_U8 *pInputStream,
OMX_U32 buffSize,
return accessUnitSize;
}
+#endif
static OMX_BOOL Check_H264_StartCode(
OMX_U8 *pInputStream,
if (pVideoDec->bThumbnailMode == OMX_TRUE)
- pDecOps->Set_DisplayDelay(hMFCHandle, 0);
+ pDecOps->Set_DisplayDelay(hMFCHandle, 0);
/* input buffer info */
Exynos_OSAL_Memset(&bufferConf, 0, sizeof(bufferConf));
} else if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
bufferConf.nSizeImage = DEFAULT_MFC_INPUT_BUFFER_SIZE;
inputBufferNumber = MFC_INPUT_BUFFER_NUM_MAX;
- }
+ }
/* should be done before prepare input buffer */
if (pInbufOps->Enable_Cacheable(hMFCHandle) != VIDEO_ERROR_NONE) {
Exynos_OSAL_Log(EXYNOS_LOG_ERROR, "Failed to set geometry for input buffer");
ret = OMX_ErrorInsufficientResources;
goto EXIT;
- }
+ }
/* setup input buffer */
if (pInbufOps->Setup(hMFCHandle, inputBufferNumber) != VIDEO_ERROR_NONE) {
Exynos_OSAL_Log(EXYNOS_LOG_TRACE, "@pVideoDec->pMFCDecInputBuffer[%d]->pVirAddr[%d]: 0x%x", i, plane, pVideoDec->pMFCDecInputBuffer[i]->pVirAddr[plane]);
}
-#ifdef SLP_PLATFORM
+#ifdef TIZEN_FEATURE_E3250
if (pExynosInputPort == NULL || pExynosOutputPort == NULL || pOMXComponent == NULL) {
Exynos_OSAL_Log(EXYNOS_LOG_ERROR, "invalid param: pExynosInputPort= %p pExynosOutputPort= %p pOMXComponent= %p", pExynosInputPort, pExynosOutputPort, pOMXComponent);
}
for (i = 0; i < pExynosInputPort->portDefinition.nBufferCountActual; i++) {
ExynosVideoPlane plane;
if (pVideoDec->bDRMPlayerMode == OMX_TRUE) {
-#ifdef SLP_PLATFORM
+#ifdef TIZEN_FEATURE_E3250
/* IL Client assigns FD value in pBuffer */
plane.addr = pExynosInputPort->extendBufferHeader[i].OMXBufferHeader->pBuffer;
#else
/* set output geometry */
Exynos_OSAL_Memset(&bufferConf, 0, sizeof(bufferConf));
- pH264Dec->hMFCH264Handle.MFCOutputColorType = bufferConf.eColorFormat = VIDEO_COLORFORMAT_NV12_TILED;
+ pH264Dec->hMFCH264Handle.MFCOutputColorType = bufferConf.eColorFormat = VIDEO_COLORFORMAT_NV12;
if (pOutbufOps->Set_Geometry(hMFCHandle, &bufferConf) != VIDEO_ERROR_NONE) {
Exynos_OSAL_Log(EXYNOS_LOG_ERROR, "Failed to set geometry for output buffer");
ret = OMX_ErrorInsufficientResources;
ret = OMX_ErrorInputDataDecodeYet;
#ifdef USE_IMMEDIATE_DISPLAY
- /* Set Immediately display for I Frame*/
- pDecOps->Set_ImmediateDisplay(hMFCHandle);
+ /* Set Immediately display for I Frame*/
+ pDecOps->Set_ImmediateDisplay(hMFCHandle);
#endif
EXIT:
OMX_DirOutput, /* This is the port index */
0,
NULL);
- }
+ }
} else if (pExynosOutputPort->bufferProcessType & BUFFER_SHARE) {
+#ifndef TIZEN_FEATURE_E3250
+ /* The input port information has already been updated */
if ((pExynosInputPort->portDefinition.format.video.nFrameWidth != pH264Dec->hMFCH264Handle.codecOutbufConf.nFrameWidth) ||
(pExynosInputPort->portDefinition.format.video.nFrameHeight != pH264Dec->hMFCH264Handle.codecOutbufConf.nFrameHeight) ||
(pExynosOutputPort->portDefinition.nBufferCountActual != pH264Dec->hMFCH264Handle.maxDPBNum)) {
pExynosInputPort->portDefinition.format.video.nFrameHeight = pH264Dec->hMFCH264Handle.codecOutbufConf.nFrameHeight;
pExynosInputPort->portDefinition.format.video.nStride = ((pH264Dec->hMFCH264Handle.codecOutbufConf.nFrameWidth + 15) & (~15));
pExynosInputPort->portDefinition.format.video.nSliceHeight = ((pH264Dec->hMFCH264Handle.codecOutbufConf.nFrameHeight + 15) & (~15));
-
+#endif
if (pVideoDec->bDRCProcessing == OMX_TRUE) {
pVideoDec->nDRCSavedBufferCount = pExynosOutputPort->portDefinition.nBufferCountActual;
}
-#ifdef SLP_PLATFORM
+#ifdef TIZEN_FEATURE_E3250
pExynosOutputPort->portDefinition.nBufferCountActual = pH264Dec->hMFCH264Handle.maxDPBNum;
pExynosOutputPort->portDefinition.nBufferCountMin = pH264Dec->hMFCH264Handle.maxDPBNum;
#else
OMX_DirOutput, /* This is the port index */
0,
NULL);
+#ifndef TIZEN_FEATURE_E3250
}
+#endif
}
if (((pVideoDec->bDRCProcessing) && (pExynosOutputPort->bufferProcessType & BUFFER_COPY)) ||
case OMX_COLOR_FormatYUV420SemiPlanar:
pExynosOutputPort->portDefinition.nBufferSize = (width * height * 3) / 2;
break;
-#ifdef SLP_PLATFORM /* NV12T fd */
+#ifdef TIZEN_FEATURE_E3250 /* NV12 fd */
+ case OMX_SEC_COLOR_FormatNV12L_DmaBuf_Fd:
case OMX_SEC_COLOR_FormatNV12T_DmaBuf_Fd:
pExynosOutputPort->portDefinition.nBufferSize = sizeof(MMVideoBuffer);
break;
Exynos_CodecBufferEnQueue(pExynosComponent, INPUT_PORT_INDEX, pVideoDec->pMFCDecInputBuffer[i]);
}
} else {
-#ifdef SLP_PLATFORM
+#ifdef TIZEN_FEATURE_E3250
if (pOMXComponent == NULL) {
Exynos_OSAL_Log(EXYNOS_LOG_ERROR, "%s : %d: invalid parm: pOMXComponent = %p", __FUNCTION__, __LINE__, pOMXComponent);
}
if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
for (i = 0; i < MFC_INPUT_BUFFER_NUM_MAX; i++) {
if (pVideoDec->pMFCDecInputBuffer[i] != NULL) {
-#ifndef SLP_PLATFORM /* do not use ion */
+#ifndef TIZEN_FEATURE_E3250 /* do not use ion */
for (plane = 0; plane < MFC_INPUT_BUFFER_PLANE; plane++) {
if (pVideoDec->pMFCDecInputBuffer[i]->pVirAddr[plane] != NULL)
Exynos_OSAL_SharedMemory_Free(pVideoDec->hSharedMemory, pVideoDec->pMFCDecInputBuffer[i]->pVirAddr[plane]);
pH264Dec->hMFCH264Handle.indexTimestamp %= MAX_TIMESTAMP;
#ifdef USE_IMMEDIATE_DISPLAY
- /* Set Immediately display for I Frame*/
+ /* Set Immediately display for I Frame*/
if (pExynosComponent->checkTimeStamp.needCheckStartTimeStamp == OMX_TRUE) {
if ( pExynosComponent->checkTimeStamp.bImmediateDisplay == OMX_FALSE) {
if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
int i = 0;
while (pSrcOutputData->buffer.singlePlaneBuffer.dataBuffer != pVideoDec->pMFCDecInputBuffer[i]->pVirAddr[0]) {
+ i++;
if (i >= MFC_INPUT_BUFFER_NUM_MAX) {
Exynos_OSAL_Log(EXYNOS_LOG_ERROR, "Can not find buffer");
ret = (OMX_ERRORTYPE)OMX_ErrorCodecDecode;
goto EXIT;
}
- i++;
}
pVideoDec->pMFCDecInputBuffer[i]->dataSize = 0;
pSrcOutputData->pPrivate = pVideoDec->pMFCDecInputBuffer[i];
pBufferInfo->imageHeight = bufferGeometry->nFrameHeight;
switch (bufferGeometry->eColorFormat) {
case VIDEO_COLORFORMAT_NV12:
-#ifdef SLP_PLATFORM /* NV12T fd */
- pBufferInfo->ColorFormat = OMX_SEC_COLOR_FormatNV12T_DmaBuf_Fd;
+#ifdef TIZEN_FEATURE_E3250 /* NV12 fd */
+ pBufferInfo->ColorFormat = OMX_SEC_COLOR_FormatNV12L_DmaBuf_Fd;
#else
pBufferInfo->ColorFormat = OMX_COLOR_FormatYUV420SemiPlanar;
#endif
/* For timestamp correction. if mfc support frametype detect */
Exynos_OSAL_Log(EXYNOS_LOG_TRACE, "disp_pic_frame_type: %d", pVideoBuffer->frameType);
//#ifdef NEED_TIMESTAMP_REORDER
- /* SLP_PLATFORM */
+ /* TIZEN_FEATURE_E3250 */
if (pVideoDec->bNeedTimestampReorder == OMX_TRUE) {
Exynos_OSAL_Log(EXYNOS_LOG_TRACE, "NEED_TIMESTAMP_REORDER ON");
if ((pVideoBuffer->frameType == VIDEO_FRAME_I)) {
Exynos_OSAL_Strcpy(pExynosPort->portDefinition.format.video.cMIMEType, "raw/video");
pExynosPort->portDefinition.format.video.pNativeRender = 0;
pExynosPort->portDefinition.format.video.bFlagErrorConcealment = OMX_FALSE;
-#ifdef SLP_PLATFORM
- pExynosPort->portDefinition.format.video.eColorFormat = OMX_SEC_COLOR_FormatNV12T_DmaBuf_Fd;
+#ifdef TIZEN_FEATURE_E3250
+ pExynosPort->portDefinition.format.video.eColorFormat = OMX_SEC_COLOR_FormatNV12L_DmaBuf_Fd;
#else
pExynosPort->portDefinition.format.video.eColorFormat = OMX_COLOR_FormatYUV420Planar;
#endif
pExynosPort->portDefinition.bEnabled = OMX_TRUE;
-#ifdef SLP_PLATFORM
+#ifdef TIZEN_FEATURE_E3250
pExynosPort->bufferProcessType = BUFFER_SHARE;
#else
pExynosPort->bufferProcessType = BUFFER_COPY;
pVideoDec->exynos_codec_enqueueAllBuffer = &H264CodecEnQueueAllBuffer;
pVideoDec->exynos_codec_resetupAllElement = &H264CodecResetupAllElement;
- pVideoDec->exynos_checkInputFrame = &Check_H264_Frame;
+ pVideoDec->exynos_checkInputFrame = NULL;
pVideoDec->exynos_codec_getCodecInputPrivateData = &GetCodecInputPrivateData;
pVideoDec->exynos_codec_getCodecOutputPrivateData = &GetCodecOutputPrivateData;
-#ifndef SLP_PLATFORM /* do not use ion */
+#ifndef TIZEN_FEATURE_E3250 /* do not use ion */
pVideoDec->hSharedMemory = Exynos_OSAL_SharedMemory_Open();
if (pVideoDec->hSharedMemory == NULL) {
Exynos_OSAL_Log(EXYNOS_LOG_ERROR, "OMX_ErrorInsufficientResources, Line:%d", __LINE__);
pExynosComponent = (EXYNOS_OMX_BASECOMPONENT *)pOMXComponent->pComponentPrivate;
pVideoDec = (EXYNOS_OMX_VIDEODEC_COMPONENT *)pExynosComponent->hComponentHandle;
-#ifndef SLP_PLATFORM /* do not use ion */
+#ifndef TIZEN_FEATURE_E3250 /* do not use ion */
Exynos_OSAL_SharedMemory_Close(pVideoDec->hSharedMemory);
#endif
Exynos_OSAL_Free(pExynosComponent->componentName);