diff options
author | James Dong <jdong@google.com> | 2010-03-26 15:23:06 -0700 |
---|---|---|
committer | Android Git Automerger <android-git-automerger@android.com> | 2010-03-26 15:23:06 -0700 |
commit | 7eb36421a3d287a51bd6be02a30bafd91d90ea4b (patch) | |
tree | a4bad6d039240135df26b814738bbdbd472a3291 | |
parent | e11d2a3524c05e06fd67c3be16caf5ffb273fcba (diff) | |
parent | 5e41d631147aa1fc9f4b52dc34941dde69f02a9a (diff) | |
download | omap3-7eb36421a3d287a51bd6be02a30bafd91d90ea4b.tar.gz |
am 5e41d631: Fix another EOS lost bug
Merge commit '5e41d631147aa1fc9f4b52dc34941dde69f02a9a' into froyo-plus-aosp
* commit '5e41d631147aa1fc9f4b52dc34941dde69f02a9a':
Fix another EOS lost bug
-rw-r--r-- | omx/video/src/openmax_il/video_decode/inc/OMX_VideoDec_Utils.h | 3 | ||||
-rw-r--r-- | omx/video/src/openmax_il/video_decode/src/OMX_VideoDec_Utils.c | 9 |
2 files changed, 12 insertions, 0 deletions
diff --git a/omx/video/src/openmax_il/video_decode/inc/OMX_VideoDec_Utils.h b/omx/video/src/openmax_il/video_decode/inc/OMX_VideoDec_Utils.h index 8a538d8..89d94c5 100644 --- a/omx/video/src/openmax_il/video_decode/inc/OMX_VideoDec_Utils.h +++ b/omx/video/src/openmax_il/video_decode/inc/OMX_VideoDec_Utils.h @@ -1020,6 +1020,9 @@ typedef struct VIDDEC_COMPONENT_PRIVATE pthread_mutex_t mutexStateChangeRequest; pthread_cond_t StateChangeCondition; + // Signal first buffer after config data should have EOS flag + OMX_BOOL firstBufferEos; + } VIDDEC_COMPONENT_PRIVATE; /*****************macro definitions*********************/ diff --git a/omx/video/src/openmax_il/video_decode/src/OMX_VideoDec_Utils.c b/omx/video/src/openmax_il/video_decode/src/OMX_VideoDec_Utils.c index 9d9ae69..bb6e591 100644 --- a/omx/video/src/openmax_il/video_decode/src/OMX_VideoDec_Utils.c +++ b/omx/video/src/openmax_il/video_decode/src/OMX_VideoDec_Utils.c @@ -1169,6 +1169,7 @@ OMX_ERRORTYPE VIDDEC_Load_Defaults (VIDDEC_COMPONENT_PRIVATE* pComponentPrivate, pComponentPrivate->bDynamicConfigurationInProgress = OMX_FALSE; pComponentPrivate->nInternalConfigBufferFilledAVC = 0; pComponentPrivate->eMBErrorReport.bEnabled = OMX_FALSE; + pComponentPrivate->firstBufferEos = OMX_FALSE; break; case VIDDEC_INIT_IDLEEXECUTING: @@ -5969,6 +5970,9 @@ OMX_ERRORTYPE VIDDEC_HandleDataBuf_FromApp(VIDDEC_COMPONENT_PRIVATE *pComponentP /* Verify if first buffer as been stored. * Handle case were only one frame is decoded */ if(pComponentPrivate->eFirstBuffer.bSaveFirstBuffer){ + if (pBuffHead->nFlags & OMX_BUFFERFLAG_EOS){ + pComponentPrivate->firstBufferEos = OMX_TRUE; + } eError = VIDDEC_CopyBuffer(pComponentPrivate, pBuffHead); if (eError != OMX_ErrorNone) { OMX_PRDSP4(pComponentPrivate->dbg, "VIDDEC_HandleDataBuf_FromApp: VIDDEC_CopyBuffer()= 0x%x\n", eError); @@ -6688,6 +6692,11 @@ OMX_ERRORTYPE VIDDEC_HandleDataBuf_FromDsp(VIDDEC_COMPONENT_PRIVATE *pComponentP } else { if(pBuffHead != NULL) { + if (pComponentPrivate->firstBufferEos){ + pComponentPrivate->firstBufferEos = OMX_FALSE; + pBuffHead->nFlags |= OMX_BUFFERFLAG_EOS; + pBuffHead->nFilledLen = 0; + } #ifdef __PERF_INSTRUMENTATION__ PERF_SendingFrame(pComponentPrivate->pPERFcomp, pBuffHead->pBuffer, |