Backport missing Android surface control fix
This commit is contained in:
parent
a6ca6a5cee
commit
97ad845a27
1 changed files with 27 additions and 1 deletions
|
@ -5,8 +5,9 @@ Subject: Disable AImageReader for ARM64/P and ARM64/Q
|
|||
---
|
||||
chrome/browser/android/chrome_startup_flags.cc | 9 +++++++++
|
||||
gpu/config/gpu_finch_features.cc | 4 ++++
|
||||
gpu/config/gpu_util.cc | 8 ++++++++
|
||||
media/base/media_switches.cc | 4 ++++
|
||||
3 files changed, 17 insertions(+)
|
||||
4 files changed, 25 insertions(+)
|
||||
|
||||
diff --git a/chrome/browser/android/chrome_startup_flags.cc b/chrome/browser/android/chrome_startup_flags.cc
|
||||
--- a/chrome/browser/android/chrome_startup_flags.cc
|
||||
|
@ -56,6 +57,31 @@ diff --git a/gpu/config/gpu_finch_features.cc b/gpu/config/gpu_finch_features.cc
|
|||
|
||||
// Used only by webview to disable SurfaceControl.
|
||||
const base::Feature kDisableSurfaceControlForWebview{
|
||||
diff --git a/gpu/config/gpu_util.cc b/gpu/config/gpu_util.cc
|
||||
--- a/gpu/config/gpu_util.cc
|
||||
+++ b/gpu/config/gpu_util.cc
|
||||
@@ -47,6 +47,9 @@ GpuFeatureStatus GetAndroidSurfaceControlFeatureStatus(
|
||||
#if !defined(OS_ANDROID)
|
||||
return kGpuFeatureStatusDisabled;
|
||||
#else
|
||||
+ if (blacklisted_features.count(GPU_FEATURE_TYPE_ANDROID_SURFACE_CONTROL))
|
||||
+ return kGpuFeatureStatusBlacklisted;
|
||||
+
|
||||
if (!gpu_preferences.enable_android_surface_control)
|
||||
return kGpuFeatureStatusDisabled;
|
||||
|
||||
@@ -288,6 +291,11 @@ void AdjustGpuFeatureStatusToWorkarounds(GpuFeatureInfo* gpu_feature_info) {
|
||||
gpu_feature_info->status_values[GPU_FEATURE_TYPE_ACCELERATED_WEBGL2] =
|
||||
kGpuFeatureStatusBlacklisted;
|
||||
}
|
||||
+
|
||||
+ if (gpu_feature_info->IsWorkaroundEnabled(DISABLE_AIMAGEREADER)) {
|
||||
+ gpu_feature_info->status_values[GPU_FEATURE_TYPE_ANDROID_SURFACE_CONTROL] =
|
||||
+ kGpuFeatureStatusBlacklisted;
|
||||
+ }
|
||||
}
|
||||
|
||||
GPUInfo* g_gpu_info_cache = nullptr;
|
||||
diff --git a/media/base/media_switches.cc b/media/base/media_switches.cc
|
||||
--- a/media/base/media_switches.cc
|
||||
+++ b/media/base/media_switches.cc
|
||||
|
|
Loading…
Add table
Reference in a new issue