summaryrefslogtreecommitdiffstats
path: root/sec_mm
diff options
context:
space:
mode:
authorSeungBeom Kim <sbcrux.kim@samsung.com>2011-12-19 20:18:25 +0900
committerJames Dong <jdong@google.com>2012-01-12 18:40:06 -0800
commit148c245007e5f4cc09b3838bba5ceee464b6ae10 (patch)
treec5a77313946684e4c22e9a391e8f3f26ff9bdc49 /sec_mm
parent7df80c1d60fc6067a10a723d70d024ddb71c058c (diff)
downloaddevice_samsung_crespo-148c245007e5f4cc09b3838bba5ceee464b6ae10.zip
device_samsung_crespo-148c245007e5f4cc09b3838bba5ceee464b6ae10.tar.gz
device_samsung_crespo-148c245007e5f4cc09b3838bba5ceee464b6ae10.tar.bz2
Fix SEC-OMX, for resolve two bugs.
related-to-bug: 5619226: ANR in com.google.android.videoeditor. related-to-bug: 5771270 [Crespo] Cannot play video when captured with time elapsed settings. Change-Id: I40f85f220b6a821d7b06cae73013ee334bb951b0 Signed-off-by: SeungBeom Kim <sbcrux.kim@samsung.com>
Diffstat (limited to 'sec_mm')
-rw-r--r--sec_mm/sec_omx/sec_omx_component/video/dec/h264dec/SEC_OMX_H264dec.c7
-rw-r--r--sec_mm/sec_omx/sec_omx_component/video/dec/mpeg4dec/SEC_OMX_Mpeg4dec.c7
2 files changed, 10 insertions, 4 deletions
diff --git a/sec_mm/sec_omx/sec_omx_component/video/dec/h264dec/SEC_OMX_H264dec.c b/sec_mm/sec_omx/sec_omx_component/video/dec/h264dec/SEC_OMX_H264dec.c
index 07e1a89..cd19cd1 100644
--- a/sec_mm/sec_omx/sec_omx_component/video/dec/h264dec/SEC_OMX_H264dec.c
+++ b/sec_mm/sec_omx/sec_omx_component/video/dec/h264dec/SEC_OMX_H264dec.c
@@ -1035,7 +1035,7 @@ OMX_ERRORTYPE SEC_MFC_H264_Decode(OMX_COMPONENTTYPE *pOMXComponent, SEC_OMX_DATA
if ((SsbSipMfcDecGetConfig(pH264Dec->hMFCH264Handle.hMFCHandle, MFC_DEC_GETCONF_FRAME_TAG, &indexTimestamp) != MFC_RET_OK) ||
(((indexTimestamp < 0) || (indexTimestamp >= MAX_TIMESTAMP)))) {
pOutputData->timeStamp = pInputData->timeStamp;
- pOutputData->nFlags = pInputData->nFlags;
+ pOutputData->nFlags = (pInputData->nFlags & (~OMX_BUFFERFLAG_EOS));
} else {
pOutputData->timeStamp = pSECComponent->timeStamp[indexTimestamp];
pOutputData->nFlags = pSECComponent->nFlags[indexTimestamp];
@@ -1055,7 +1055,7 @@ OMX_ERRORTYPE SEC_MFC_H264_Decode(OMX_COMPONENTTYPE *pOMXComponent, SEC_OMX_DATA
if(status == MFC_GETOUTBUF_DECODING_ONLY) {
if (((pInputData->nFlags & OMX_BUFFERFLAG_EOS) != OMX_BUFFERFLAG_EOS) &&
- (pSECComponent->bSaveFlagEOS == OMX_TRUE)) {
+ ((pSECComponent->bSaveFlagEOS == OMX_TRUE) || (pSECComponent->getAllDelayBuffer == OMX_TRUE))) {
pInputData->nFlags |= OMX_BUFFERFLAG_EOS;
pSECComponent->getAllDelayBuffer = OMX_TRUE;
ret = OMX_ErrorInputDataDecodeYet;
@@ -1074,6 +1074,8 @@ OMX_ERRORTYPE SEC_MFC_H264_Decode(OMX_COMPONENTTYPE *pOMXComponent, SEC_OMX_DATA
} else
#endif
if ((pInputData->nFlags & OMX_BUFFERFLAG_EOS) == OMX_BUFFERFLAG_EOS) {
+ //setConfVal = 1;
+ //SsbSipMfcDecSetConfig(pH264Dec->hMFCH264Handle.hMFCHandle, MFC_DEC_SETCONF_IS_LAST_FRAME, &setConfVal);
pInputData->nFlags = (pOutputData->nFlags & (~OMX_BUFFERFLAG_EOS));
pSECComponent->getAllDelayBuffer = OMX_TRUE;
ret = OMX_ErrorInputDataDecodeYet;
@@ -1093,6 +1095,7 @@ OMX_ERRORTYPE SEC_MFC_H264_Decode(OMX_COMPONENTTYPE *pOMXComponent, SEC_OMX_DATA
}
if ((pH264Dec->bFirstFrame == OMX_TRUE) &&
((pOutputData->nFlags & OMX_BUFFERFLAG_EOS) == OMX_BUFFERFLAG_EOS)) {
+ pInputData->nFlags = (pInputData->nFlags | OMX_BUFFERFLAG_EOS);
pOutputData->nFlags = (pOutputData->nFlags & (~OMX_BUFFERFLAG_EOS));
}
diff --git a/sec_mm/sec_omx/sec_omx_component/video/dec/mpeg4dec/SEC_OMX_Mpeg4dec.c b/sec_mm/sec_omx/sec_omx_component/video/dec/mpeg4dec/SEC_OMX_Mpeg4dec.c
index 052a4c9..dc99826 100644
--- a/sec_mm/sec_omx/sec_omx_component/video/dec/mpeg4dec/SEC_OMX_Mpeg4dec.c
+++ b/sec_mm/sec_omx/sec_omx_component/video/dec/mpeg4dec/SEC_OMX_Mpeg4dec.c
@@ -1180,7 +1180,7 @@ OMX_ERRORTYPE SEC_MFC_Mpeg4_Decode(OMX_COMPONENTTYPE *pOMXComponent, SEC_OMX_DAT
if ((SsbSipMfcDecGetConfig(hMFCHandle, MFC_DEC_GETCONF_FRAME_TAG, &indexTimestamp) != MFC_RET_OK) ||
(((indexTimestamp < 0) || (indexTimestamp >= MAX_TIMESTAMP)))) {
pOutputData->timeStamp = pInputData->timeStamp;
- pOutputData->nFlags = pInputData->nFlags;
+ pOutputData->nFlags = (pInputData->nFlags & (~OMX_BUFFERFLAG_EOS));
} else {
pOutputData->timeStamp = pSECComponent->timeStamp[indexTimestamp];
pOutputData->nFlags = pSECComponent->nFlags[indexTimestamp];
@@ -1200,7 +1200,7 @@ OMX_ERRORTYPE SEC_MFC_Mpeg4_Decode(OMX_COMPONENTTYPE *pOMXComponent, SEC_OMX_DAT
if (status == MFC_GETOUTBUF_DECODING_ONLY) {
if (((pInputData->nFlags & OMX_BUFFERFLAG_EOS) != OMX_BUFFERFLAG_EOS) &&
- (pSECComponent->bSaveFlagEOS == OMX_TRUE)) {
+ ((pSECComponent->bSaveFlagEOS == OMX_TRUE) || (pSECComponent->getAllDelayBuffer == OMX_TRUE))) {
pInputData->nFlags |= OMX_BUFFERFLAG_EOS;
pSECComponent->getAllDelayBuffer = OMX_TRUE;
ret = OMX_ErrorInputDataDecodeYet;
@@ -1219,6 +1219,8 @@ OMX_ERRORTYPE SEC_MFC_Mpeg4_Decode(OMX_COMPONENTTYPE *pOMXComponent, SEC_OMX_DAT
} else
#endif
if ((pInputData->nFlags & OMX_BUFFERFLAG_EOS) == OMX_BUFFERFLAG_EOS) {
+ //configValue = 1;
+ //SsbSipMfcDecSetConfig(pMpeg4Dec->hMFCMpeg4Handle.hMFCHandle, MFC_DEC_SETCONF_IS_LAST_FRAME, &configValue);
pInputData->nFlags = (pOutputData->nFlags & (~OMX_BUFFERFLAG_EOS));
pSECComponent->getAllDelayBuffer = OMX_TRUE;
ret = OMX_ErrorInputDataDecodeYet;
@@ -1238,6 +1240,7 @@ OMX_ERRORTYPE SEC_MFC_Mpeg4_Decode(OMX_COMPONENTTYPE *pOMXComponent, SEC_OMX_DAT
}
if ((pMpeg4Dec->bFirstFrame == OMX_TRUE) &&
((pOutputData->nFlags & OMX_BUFFERFLAG_EOS) == OMX_BUFFERFLAG_EOS)) {
+ pInputData->nFlags = (pInputData->nFlags | OMX_BUFFERFLAG_EOS);
pOutputData->nFlags = (pOutputData->nFlags & (~OMX_BUFFERFLAG_EOS));
}