| Index: gpu/ipc/host/gpu_memory_buffer_support.cc
|
| diff --git a/gpu/ipc/host/gpu_memory_buffer_support.cc b/gpu/ipc/host/gpu_memory_buffer_support.cc
|
| index cbd3655936503cd5cffe22ea2aae69d287d31f39..860257c0d83a242763624c45c5c00c4b6e5d3cc3 100644
|
| --- a/gpu/ipc/host/gpu_memory_buffer_support.cc
|
| +++ b/gpu/ipc/host/gpu_memory_buffer_support.cc
|
| @@ -10,14 +10,16 @@
|
| #include "gpu/ipc/common/gpu_memory_buffer_support.h"
|
| #include "gpu/ipc/host/gpu_switches.h"
|
| #include "ui/gl/gl_bindings.h"
|
| +#include "ui/gl/gl_implementation.h"
|
| #include "ui/gl/gl_switches.h"
|
|
|
| namespace gpu {
|
|
|
| bool AreNativeGpuMemoryBuffersEnabled() {
|
| - // Disable native buffers when using Mesa.
|
| + // Disable native buffers when using software GL.
|
| if (base::CommandLine::ForCurrentProcess()->GetSwitchValueASCII(
|
| - switches::kUseGL) == gl::kGLImplementationOSMesaName) {
|
| + switches::kUseGL) ==
|
| + gl::GetGLImplementationName(gl::GetSoftwareGLImplementation())) {
|
| return false;
|
| }
|
|
|
| @@ -57,10 +59,11 @@ GpuMemoryBufferConfigurationSet GetNativeGpuMemoryBufferConfigurations() {
|
| }
|
| }
|
|
|
| - // Disable native buffers only when using Mesa.
|
| + // Disable native buffers only when using software GL.
|
| bool force_native_gpu_read_write_formats =
|
| base::CommandLine::ForCurrentProcess()->GetSwitchValueASCII(
|
| - switches::kUseGL) != gl::kGLImplementationOSMesaName;
|
| + switches::kUseGL) !=
|
| + gl::GetGLImplementationName(gl::GetSoftwareGLImplementation());
|
| if (force_native_gpu_read_write_formats) {
|
| const gfx::BufferFormat kGPUReadWriteFormats[] = {
|
| gfx::BufferFormat::BGR_565, gfx::BufferFormat::RGBA_8888,
|
|
|