summaryrefslogtreecommitdiffstats
path: root/media
diff options
context:
space:
mode:
authorLajos Molnar <lajos@google.com>2013-09-12 14:19:50 -0700
committerAndroid Git Automerger <android-git-automerger@android.com>2013-09-12 14:19:50 -0700
commit49d62d66a1578da3a2115ab9f5f128f8916659e4 (patch)
tree723b5ed96dc70628478ca70bb07e20abbd60b7fa /media
parent8a220740cd77eb844123d3914190a94513797b40 (diff)
parent877c673c3d3794e89e4677d448f38f77bdee7fdb (diff)
downloadframeworks_av-49d62d66a1578da3a2115ab9f5f128f8916659e4.zip
frameworks_av-49d62d66a1578da3a2115ab9f5f128f8916659e4.tar.gz
frameworks_av-49d62d66a1578da3a2115ab9f5f128f8916659e4.tar.bz2
am 877c673c: Merge "ACodec: fix flush/resume for decoder-output-meta-data mode" into klp-dev
* commit '877c673c3d3794e89e4677d448f38f77bdee7fdb': ACodec: fix flush/resume for decoder-output-meta-data mode
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();
}
}