summaryrefslogtreecommitdiffstats
path: root/media
diff options
context:
space:
mode:
authorLajos Molnar <lajos@google.com>2013-09-12 21:16:57 +0000
committerAndroid (Google) Code Review <android-gerrit@google.com>2013-09-12 21:16:57 +0000
commit877c673c3d3794e89e4677d448f38f77bdee7fdb (patch)
tree4530300a3cf3f0bab8bd3c12b569a735eb8c01cf /media
parentdc33c542351449ceee95cc50a9009f495e7c72ba (diff)
parentc38fcfba95f711e5738e4c72bd5499317a2f30d9 (diff)
downloadframeworks_av-877c673c3d3794e89e4677d448f38f77bdee7fdb.zip
frameworks_av-877c673c3d3794e89e4677d448f38f77bdee7fdb.tar.gz
frameworks_av-877c673c3d3794e89e4677d448f38f77bdee7fdb.tar.bz2
Merge "ACodec: fix flush/resume for decoder-output-meta-data mode" into klp-dev
Diffstat (limited to 'media')
-rw-r--r--media/libstagefright/ACodec.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/media/libstagefright/ACodec.cpp b/media/libstagefright/ACodec.cpp
index 2e55c4f..5c3abd0 100644
--- a/media/libstagefright/ACodec.cpp
+++ b/media/libstagefright/ACodec.cpp
@@ -2366,6 +2366,10 @@ void ACodec::waitUntilAllPossibleNativeWindowBuffersAreReturnedToUs() {
while (countBuffersOwnedByNativeWindow() > (size_t)minUndequeuedBufs
&& dequeueBufferFromNativeWindow() != NULL) {
+ // these buffers will be submitted as regular buffers; account for this
+ if (mStoreMetaDataInOutputBuffers && mMetaDataBuffersToSubmit > 0) {
+ --mMetaDataBuffersToSubmit;
+ }
}
}
@@ -4000,10 +4004,9 @@ void ACodec::ExecutingState::submitRegularOutputBuffers() {
}
void ACodec::ExecutingState::submitOutputBuffers() {
+ submitRegularOutputBuffers();
if (mCodec->mStoreMetaDataInOutputBuffers) {
submitOutputMetaBuffers();
- } else {
- submitRegularOutputBuffers();
}
}