venc/osal: modified a bFirstInput handling position
authorTaehwan Kim <t_h.kim@samsung.com>
Tue, 20 Nov 2012 00:03:37 +0000 (00:03 +0000)
committerTaehwan Kim <t_h.kim@samsung.com>
Thu, 22 Nov 2012 05:50:27 +0000 (05:50 +0000)
modified a bFirstInput handling position
to venc from osal.

Change-Id: I3b042db705b91c41104721c6a9926192166c414d
Signed-off-by: Taehwan Kim <t_h.kim@samsung.com>
component/video/enc/Exynos_OMX_VencControl.c
osal/Exynos_OSAL_Android.cpp

index facba5f87083918f97c877a834c7b33b89ef37e0..07794a1471fc579d10d3a27c64565ab930259592 100644 (file)
@@ -1566,7 +1566,15 @@ OMX_ERRORTYPE Exynos_OMX_VideoEncodeSetParameter(
 #ifdef USE_STOREMETADATA
     case OMX_IndexParamStoreMetaDataBuffer:
     {
+        EXYNOS_OMX_VIDEOENC_COMPONENT *pVideoEnc = (EXYNOS_OMX_VIDEOENC_COMPONENT *)pExynosComponent->hComponentHandle;
+        if (pVideoEnc == NULL) {
+            ret = OMX_ErrorBadParameter;
+            goto EXIT;
+        }
+
         ret = Exynos_OSAL_SetANBParameter(hComponent, nParamIndex, pComponentParameterStructure);
+        if (ret == OMX_ErrorNone)
+            pVideoEnc->bFirstInput = OMX_TRUE;
     }
         break;
 #endif
index 224893a29b270ae706abaf874c27a2fa008eb7fb..42d1284c6dafbe163b57f36dc5387266ad9c93f2 100644 (file)
@@ -46,7 +46,6 @@
 #include "Exynos_OMX_Basecomponent.h"
 #include "Exynos_OMX_Macros.h"
 #include "Exynos_OMX_Vdec.h"
-#include "Exynos_OMX_Venc.h"
 #include "Exynos_OSAL_Android.h"
 #include "exynos_format.h"
 
@@ -509,7 +508,6 @@ OMX_ERRORTYPE Exynos_OSAL_SetANBParameter(
 
     case OMX_IndexParamStoreMetaDataBuffer:
     {
-        EXYNOS_OMX_VIDEOENC_COMPONENT *pVideoEnc = (EXYNOS_OMX_VIDEOENC_COMPONENT *)pExynosComponent->hComponentHandle;;
         StoreMetaDataInBuffersParams *pANBParams = (StoreMetaDataInBuffersParams *) ComponentParameterStructure;
         OMX_U32 portIndex = pANBParams->nPortIndex;
         EXYNOS_OMX_BASEPORT *pExynosPort = NULL;
@@ -534,7 +532,6 @@ OMX_ERRORTYPE Exynos_OSAL_SetANBParameter(
         }
 
         pExynosPort->bStoreMetaData = pANBParams->bStoreMetaData;
-        pVideoEnc->bFirstInput = OMX_TRUE;
     }
         break;