aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--videocodec/OMXVideoDecoderVP9Hybrid.cpp14
1 files changed, 14 insertions, 0 deletions
diff --git a/videocodec/OMXVideoDecoderVP9Hybrid.cpp b/videocodec/OMXVideoDecoderVP9Hybrid.cpp
index 483e484..cbca17c 100644
--- a/videocodec/OMXVideoDecoderVP9Hybrid.cpp
+++ b/videocodec/OMXVideoDecoderVP9Hybrid.cpp
@@ -320,6 +320,13 @@ OMX_ERRORTYPE OMXVideoDecoderVP9Hybrid::FillRenderBuffer(OMX_BUFFERHEADERTYPE **
unsigned char *dst = buffer->pBuffer;
fb_index = mGetRawDataOutput(mCtx,mHybridCtx,dst,height,stride);
if (fb_index == -1) {
+ if (inportBufferFlags & OMX_BUFFERFLAG_EOS) {
+ // eos frame is non-shown frame
+ buffer->nFlags = OMX_BUFFERFLAG_EOS;
+ buffer->nOffset = 0;
+ buffer->nFilledLen = 0;
+ return OMX_ErrorNone;
+ }
LOGV("vpx_codec_get_frame return NULL.");
return OMX_ErrorNotReady;
}
@@ -333,6 +340,13 @@ OMX_ERRORTYPE OMXVideoDecoderVP9Hybrid::FillRenderBuffer(OMX_BUFFERHEADERTYPE **
fb_index = mGetOutput(mCtx,mHybridCtx, &mDecodedImageNewWidth, &mDecodedImageNewHeight);
if (fb_index == -1) {
+ if (inportBufferFlags & OMX_BUFFERFLAG_EOS) {
+ // eos frame is no-shown frame
+ buffer->nFlags = OMX_BUFFERFLAG_EOS;
+ buffer->nOffset = 0;
+ buffer->nFilledLen = 0;
+ return OMX_ErrorNone;
+ }
LOGV("vpx_codec_get_frame return NULL.");
return OMX_ErrorNotReady;
}