diff options
Diffstat (limited to 'chromium/ui/gl/gl_context_glx.cc')
-rw-r--r-- | chromium/ui/gl/gl_context_glx.cc | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/chromium/ui/gl/gl_context_glx.cc b/chromium/ui/gl/gl_context_glx.cc index d66d3119382..280ee88ec7f 100644 --- a/chromium/ui/gl/gl_context_glx.cc +++ b/chromium/ui/gl/gl_context_glx.cc @@ -172,9 +172,14 @@ bool GLContextGLX::Initialize(GLSurface* compatible_surface, if (GLSurfaceGLX::IsCreateContextSupported()) { DVLOG(1) << "GLX_ARB_create_context supported."; - context_ = CreateHighestVersionContext( - display_, static_cast<GLXFBConfig>(compatible_surface->GetConfig()), - share_handle); + if (base::CommandLine::ForCurrentProcess()->HasSwitch(switches::kCreateDefaultGLContext)) { + context_ = CreateContextAttribs(display_, static_cast<GLXFBConfig>(compatible_surface->GetConfig()), + share_handle, GLVersion(0, 0), 0); + } else { + context_ = CreateHighestVersionContext( + display_, static_cast<GLXFBConfig>(compatible_surface->GetConfig()), + share_handle); + } if (!context_) { LOG(ERROR) << "Failed to create GL context with " << "glXCreateContextAttribsARB."; |