From e76d5aaad85cf7fdcd303dd8864906eb4c8b58aa Mon Sep 17 00:00:00 2001 From: Lajos Molnar Date: Fri, 30 Jan 2015 17:44:31 -0800 Subject: [PATCH] exynos: vdec: support disabling metadata and native buffer modes Bug: 19179288 Change-Id: I57495379be6170fec6e07ea9a1f67ed81aeeadf2 --- .../openmax/exynos_omx/osal/Exynos_OSAL_Android.cpp | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/exynos_omx/openmax/exynos_omx/osal/Exynos_OSAL_Android.cpp b/exynos_omx/openmax/exynos_omx/osal/Exynos_OSAL_Android.cpp index 997b926..b91365b 100644 --- a/exynos_omx/openmax/exynos_omx/osal/Exynos_OSAL_Android.cpp +++ b/exynos_omx/openmax/exynos_omx/osal/Exynos_OSAL_Android.cpp @@ -696,6 +696,12 @@ OMX_ERRORTYPE Exynos_OSAL_SetANBParameter( pExynosPort->bufferProcessType = BUFFER_SHARE; pExynosPort->portDefinition.format.video.eColorFormat = (OMX_COLOR_FORMATTYPE)OMX_SEC_COLOR_FormatNV12Tiled; Exynos_OSAL_Log(EXYNOS_LOG_TRACE, "OMX_IndexParamEnableAndroidBuffers & bufferProcessType change to BUFFER_SHARE"); + } else if ((portIndex == OUTPUT_PORT_INDEX) && + (pExynosPort->bStoreMetaData == OMX_FALSE && pExynosPort->bIsANBEnabled == OMX_FALSE) && + pExynosPort->bufferProcessType == BUFFER_SHARE) { + pExynosPort->bufferProcessType = (EXYNOS_OMX_BUFFERPROCESS_TYPE)(BUFFER_COPY | BUFFER_ANBSHARE); + pExynosPort->portDefinition.format.video.eColorFormat = OMX_COLOR_FormatYUV420Planar; + Exynos_OSAL_Log(EXYNOS_LOG_TRACE, "No OMX_IndexParamEnableAndroidBuffers => reset bufferProcessType"); } } break; @@ -789,6 +795,12 @@ OMX_ERRORTYPE Exynos_OSAL_SetANBParameter( pExynosPort->bufferProcessType = BUFFER_SHARE; pExynosPort->portDefinition.format.video.eColorFormat = (OMX_COLOR_FORMATTYPE)OMX_SEC_COLOR_FormatNV12Tiled; Exynos_OSAL_Log(EXYNOS_LOG_TRACE, "OMX_IndexParamStoreMetaDataBuffer & bufferProcessType change to BUFFER_SHARE"); + } else if ((portIndex == OUTPUT_PORT_INDEX) && + (pExynosPort->bStoreMetaData == OMX_FALSE && pExynosPort->bIsANBEnabled == OMX_FALSE) && + pExynosPort->bufferProcessType == BUFFER_SHARE) { + pExynosPort->bufferProcessType = (EXYNOS_OMX_BUFFERPROCESS_TYPE)(BUFFER_COPY | BUFFER_ANBSHARE); + pExynosPort->portDefinition.format.video.eColorFormat = OMX_COLOR_FormatYUV420Planar; + Exynos_OSAL_Log(EXYNOS_LOG_TRACE, "No OMX_IndexParamStoreMetaDataBuffer => reset bufferProcessType"); } } -- 2.20.1