From c98025c07f77d5090fcb40a194d1966ede6c2ea7 Mon Sep 17 00:00:00 2001 From: Austin Hu Date: Thu, 30 Jun 2016 11:48:59 +0800 Subject: Handle the skip decoding case. Bug: 32242956 BZ: 50956, 49995 Change-Id: I09b76e58c4eda32bdae5774f1d40a3105396b65c Signed-off-by: Austin Hu Signed-off-by: Xin Wang --- videocodec/OMXVideoDecoderVP9Hybrid.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/videocodec/OMXVideoDecoderVP9Hybrid.cpp b/videocodec/OMXVideoDecoderVP9Hybrid.cpp index 53dbd48..fe8d5f8 100644 --- a/videocodec/OMXVideoDecoderVP9Hybrid.cpp +++ b/videocodec/OMXVideoDecoderVP9Hybrid.cpp @@ -379,6 +379,11 @@ OMX_ERRORTYPE OMXVideoDecoderVP9Hybrid::ProcessorProcess( // drain the last frame, keep the current input buffer res = mDecoderDecode(mCtx,mHybridCtx,NULL,0,true); retains[INPORT_INDEX] = BUFFER_RETAIN_GETAGAIN; + } else if (res == -3) { + LOGW("on2 decoder skipped to decode the frame."); + (*pBuffers[OUTPORT_INDEX])->nOffset = 0; + (*pBuffers[OUTPORT_INDEX])->nFilledLen = 0; + return OMX_ErrorNone; } else { LOGE("on2 decoder failed to decode frame."); return OMX_ErrorBadParameter; -- cgit v1.2.3