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

Unified Diff: content/common/gpu/media/android_video_decode_accelerator.cc

Issue 1785153004: Made full screen video with DevTools not flash black on Android. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: switched to 2d textures Created 4 years, 9 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
Index: content/common/gpu/media/android_video_decode_accelerator.cc
diff --git a/content/common/gpu/media/android_video_decode_accelerator.cc b/content/common/gpu/media/android_video_decode_accelerator.cc
index d058451b38bf5b7da68e6991668eaabd09447f29..042d01d5cbd51f0a45b723556b303e668ad2e686 100644
--- a/content/common/gpu/media/android_video_decode_accelerator.cc
+++ b/content/common/gpu/media/android_video_decode_accelerator.cc
@@ -802,6 +802,11 @@ void AndroidVideoDecodeAccelerator::AssignPictureBuffers(
return;
}
+ bool have_context = false;
DaleCurtis 2016/03/28 18:02:02 const bool have_context = make_context_current_.Ru
liberato (no reviews please) 2016/03/28 20:58:18 Done.
+ if ((have_context = make_context_current_.Run()) == false) {
+ LOG(WARNING) << "Failed make GL context current for Assign, continuing.";
+ }
+
for (size_t i = 0; i < buffers.size(); ++i) {
if (buffers[i].size() != size_) {
POST_ERROR(INVALID_ARGUMENT,
@@ -818,7 +823,7 @@ void AndroidVideoDecodeAccelerator::AssignPictureBuffers(
// about "zombies" for why we maintain this set in the first place.
dismissed_picture_ids_.erase(id);
- strategy_->AssignOnePictureBuffer(buffers[i]);
+ strategy_->AssignOnePictureBuffer(buffers[i], have_context);
}
TRACE_COUNTER1("media", "AVDA::FreePictureIds", free_picture_ids_.size());
DoIOTask(true);

Powered by Google App Engine
This is Rietveld 408576698