0

Use SwANGLE as default software renderer on MacOS

This CL changes the default software renderer from legacy SwiftShader GL
to SwANGLE on MacOS.

Bug: chromium:1060139
Change-Id: Iaad225ee7d652d0808b71a7816d3ca37edbedfb2
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3399886
Reviewed-by: Andrey Kosyakov <caseq@chromium.org>
Reviewed-by: Zhenyao Mo <zmo@chromium.org>
Reviewed-by: Peter Kvitek <kvitekp@chromium.org>
Commit-Queue: Alexis Hétu <sugoi@chromium.org>
Cr-Commit-Position: refs/heads/main@{#961891}
This commit is contained in:
Alexis Hetu
2022-01-21 14:14:42 +00:00
committed by Chromium LUCI CQ
parent 2707af118e
commit ab15e697a2
4 changed files with 4 additions and 4 deletions
content/browser/gpu
gpu/config
headless/public
ui/gl/init

@ -1340,7 +1340,7 @@ void GpuDataManagerImplPrivate::AppendGpuCommandLine(
break;
case gpu::GpuMode::SWIFTSHADER: {
bool legacy_software_gl = true;
#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN)
#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC)
// This setting makes WebGL run on SwANGLE instead of SwiftShader GL.
legacy_software_gl = false;
#endif

@ -754,7 +754,7 @@ bool EnableSwiftShaderIfNeeded(base::CommandLine* command_line,
gpu_feature_info.status_values[GPU_FEATURE_TYPE_ACCELERATED_GL] !=
kGpuFeatureStatusEnabled) {
bool legacy_software_gl = true;
#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN)
#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC)
// This setting makes WebGL run on SwANGLE instead of SwiftShader GL.
legacy_software_gl = false;
#endif

@ -42,7 +42,7 @@ Options::Options(int argc, const char** argv)
user_agent(content::BuildUserAgentFromProduct(product_name_and_version)),
window_size(kDefaultWindowSize),
font_render_hinting(kDefaultFontRenderHinting) {
#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN)
#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC)
gl_implementation = gl::kGLImplementationANGLEName;
angle_implementation = gl::kANGLEImplementationSwiftShaderForWebGLName;
#endif

@ -171,7 +171,7 @@ bool InitializeGLOneOffPlatformHelper(bool init_extensions) {
} // namespace
GLImplementationParts GetSoftwareGLImplementationForPlatform() {
#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX)
#if BUILDFLAG(IS_WIN) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_MAC)
return GetSoftwareGLImplementation();
#else
return GetLegacySoftwareGLImplementation();