From 617daafc1cf7580b7d80ead8a7e21bb5cbf525cf Mon Sep 17 00:00:00 2001 From: Kim Zhang Date: Tue, 29 Dec 2015 14:50:52 +0800 Subject: StagefrightMetadataRetriever: correct the status flag In case of EOS or ERROR from source, correct the status flag and clear the input index to continue to wait for output buffer from decoder. This is to fix thumbnail generation failure for some clips with one frame. CRs-Fixed: 951250 Change-Id: If9889dbcc32bf49368add408a317da026879fec8 --- media/libstagefright/StagefrightMetadataRetriever.cpp | 3 +++ 1 file changed, 3 insertions(+) (limited to 'media/libstagefright/StagefrightMetadataRetriever.cpp') diff --git a/media/libstagefright/StagefrightMetadataRetriever.cpp b/media/libstagefright/StagefrightMetadataRetriever.cpp index 5b96040..d39f34b 100644 --- a/media/libstagefright/StagefrightMetadataRetriever.cpp +++ b/media/libstagefright/StagefrightMetadataRetriever.cpp @@ -273,6 +273,9 @@ static VideoFrame *extractVideoFrame( if (err != OK) { ALOGW("Input Error or EOS"); haveMoreInputs = false; + //correct the status to continue to get output from decoder + err = OK; + inputIndex = -1; break; } -- cgit v1.1