summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorAndreas Huber <andih@google.com>2013-04-19 11:55:18 -0700
committerAndreas Huber <andih@google.com>2013-04-19 11:55:18 -0700
commit0ae2001f40587556e2f5ed56f791292fb5e9a329 (patch)
tree8b4980c76a87eb6826399dc11d8d771ee9628fcb /include
parent005bb86bd99077283df1968958d5c514a3bfa16a (diff)
downloadframeworks_av-0ae2001f40587556e2f5ed56f791292fb5e9a329.zip
frameworks_av-0ae2001f40587556e2f5ed56f791292fb5e9a329.tar.gz
frameworks_av-0ae2001f40587556e2f5ed56f791292fb5e9a329.tar.bz2
A flush of a video decoder connected to a native window must reclaim
output buffers already queued for rendering before considering a flush completed. Otherwise the decoder may not have enough output buffers to continue decoding after the discontinuity and we'll never dequeue more from the native window. Change-Id: I42e275dc336568e180081c6d7c0dc05fc9637c79 related-to-bug: 8578467
Diffstat (limited to 'include')
-rw-r--r--include/media/stagefright/ACodec.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/include/media/stagefright/ACodec.h b/include/media/stagefright/ACodec.h
index 5cfe5bc..34bae29 100644
--- a/include/media/stagefright/ACodec.h
+++ b/include/media/stagefright/ACodec.h
@@ -264,12 +264,16 @@ private:
status_t pushBlankBuffersToNativeWindow();
- // Returns true iff all buffers on the given port have status OWNED_BY_US.
+ // Returns true iff all buffers on the given port have status
+ // OWNED_BY_US or OWNED_BY_NATIVE_WINDOW.
bool allYourBuffersAreBelongToUs(OMX_U32 portIndex);
bool allYourBuffersAreBelongToUs();
+ void waitUntilAllPossibleNativeWindowBuffersAreReturnedToUs();
+
size_t countBuffersOwnedByComponent(OMX_U32 portIndex) const;
+ size_t countBuffersOwnedByNativeWindow() const;
void deferMessage(const sp<AMessage> &msg);
void processDeferredMessages();