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

Unified Diff: media/gpu/android_video_decode_accelerator.cc

Issue 2889603005: Position overlays in AVDACodecImage (Closed)
Patch Set: rebased Created 3 years, 7 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 | media/gpu/avda_codec_image.h » ('j') | 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 39bfd4b9d944996acdb09486324d49bf3d111722..d9e9b48d3c9d8ce6d2adfdaf018734fe17d8b5a8 100644
--- a/media/gpu/android_video_decode_accelerator.cc
+++ b/media/gpu/android_video_decode_accelerator.cc
@@ -497,19 +497,10 @@ void AndroidVideoDecodeAccelerator::InitializePictureBufferManager() {
// TODO(liberato): it doesn't make sense anymore for the PictureBufferManager
// to create the surface texture. We can probably make an overlay impl out
// of it, and provide the surface texture to |picture_buffer_manager_|.
- if (incoming_bundle_->overlay) {
- picture_buffer_manager_.InitializeForOverlay();
- } else {
- incoming_bundle_->surface_texture_surface =
- picture_buffer_manager_.InitializeForSurfaceTexture();
- incoming_bundle_->surface_texture =
- picture_buffer_manager_.surface_texture();
-
- if (!incoming_bundle_->surface_texture) {
- NOTIFY_ERROR(PLATFORM_FAILURE, "Could not allocate surface texture");
- incoming_bundle_ = nullptr;
- return;
- }
+ if (!picture_buffer_manager_.Initialize(incoming_bundle_)) {
+ NOTIFY_ERROR(PLATFORM_FAILURE, "Could not allocate surface texture");
+ incoming_bundle_ = nullptr;
+ return;
}
// If we have a media codec, then SetSurface. If that doesn't work, then we
« no previous file with comments | « no previous file | media/gpu/avda_codec_image.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698