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

Unified Diff: content/browser/gpu/gpu_data_manager_impl_private.cc

Issue 1560953002: Implement fallback from WMPI to WMPA. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Only include MediaCodecUtil on Android. Created 4 years, 11 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 | content/renderer/media/android/webmediaplayer_android.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/gpu/gpu_data_manager_impl_private.cc
diff --git a/content/browser/gpu/gpu_data_manager_impl_private.cc b/content/browser/gpu/gpu_data_manager_impl_private.cc
index 926886d3e8baa457f780b054064c5bb8e481d2a6..bb8e0337f57c2a20f0e9ca5e00961204f1f58e62 100644
--- a/content/browser/gpu/gpu_data_manager_impl_private.cc
+++ b/content/browser/gpu/gpu_data_manager_impl_private.cc
@@ -933,6 +933,22 @@ bool GpuDataManagerImplPrivate::ShouldDisableAcceleratedVideoDecode(
return true;
if (group_name == "Disabled")
return true;
+
+ // Accelerated decode is never available with --disable-gpu. It is also
+ // currently non-functional with --single-process and --in-process-gpu, but
+ // these should be fixable. We set the --disable-accelerated-video-decode flag
+ // in these cases so that the renderer can be aware. (Which is important on
+ // Android where there is no fallback once WMPI is selected.)
+ //
+ // TODO(sandersd): Enable support for accelerated decode with
+ // --in-process-gpu, at least on Android (necessary to support WebView).
+ // http://crbug.com/574935.
+ if (command_line->HasSwitch(switches::kDisableGpu) ||
+ command_line->HasSwitch(switches::kSingleProcess) ||
+ command_line->HasSwitch(switches::kInProcessGPU)) {
+ return true;
+ }
+
return false;
}
« no previous file with comments | « no previous file | content/renderer/media/android/webmediaplayer_android.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698