Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(723)

Unified Diff: media/gpu/android_video_decode_accelerator.cc

Issue 2084063003: Merge M52: "Immediately reset for vp8 when there's nothing to flush." (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2743
Patch Set: Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/gpu/android_video_decode_accelerator.cc
diff --git a/media/gpu/android_video_decode_accelerator.cc b/media/gpu/android_video_decode_accelerator.cc
index 9a017b8b64e0892a593b93387185c8f1d5afba4c..c290e3784e1cfdde22cae669bf7c41b72bcff18a 100644
--- a/media/gpu/android_video_decode_accelerator.cc
+++ b/media/gpu/android_video_decode_accelerator.cc
@@ -1276,7 +1276,8 @@ void AndroidVideoDecodeAccelerator::Reset() {
// Some VP8 files require complete MediaCodec drain before we can call
// MediaCodec.flush() or MediaCodec.reset(). http://crbug.com/598963.
- if (media_codec_ && codec_config_->codec_ == media::kCodecVP8) {
+ if (media_codec_ && codec_config_->codec_ == media::kCodecVP8 &&
+ !bitstream_buffers_in_decoder_.empty()) {
// Postpone ResetCodecState() after the drain.
StartCodecDrain(DRAIN_FOR_RESET);
} else {
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698