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

Unified Diff: ui/gl/gl_context_glx.cc

Issue 1052153002: Use the desktop GL core profile on Linux when ES3 support is requested. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added link to bug in TODO. Created 5 years, 9 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 | « gpu/config/gpu_info_collector.cc ('k') | ui/gl/gl_context_x11.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/gl/gl_context_glx.cc
diff --git a/ui/gl/gl_context_glx.cc b/ui/gl/gl_context_glx.cc
index e5b1cc1a69121175716801ad976acffdfaced63d..b7d7e214292cade8c0fa935f52e1e4dc04caeaf4 100644
--- a/ui/gl/gl_context_glx.cc
+++ b/ui/gl/gl_context_glx.cc
@@ -38,6 +38,18 @@ bool GLContextGLX::Initialize(
if (GLSurfaceGLX::IsCreateContextSupported()) {
DVLOG(1) << "GLX_ARB_create_context supported.";
std::vector<int> attribs;
+ if (gfx::GetGLImplementation() ==
+ gfx::kGLImplementationDesktopGLCoreProfile) {
+ // TODO(kbr): NVIDIA's driver doesn't return a later context
+ // version if any version later than 3.1 is requested. We
+ // explicitly want to request a 3.2+ context with no support for
+ // the compatibility profile. WebGL 2.0 support currently
+ // requires a 4.2 context. crbug.com/473427
+ attribs.push_back(GLX_CONTEXT_MAJOR_VERSION_ARB);
+ attribs.push_back(4);
+ attribs.push_back(GLX_CONTEXT_MINOR_VERSION_ARB);
+ attribs.push_back(2);
+ }
if (GLSurfaceGLX::IsCreateContextRobustnessSupported()) {
DVLOG(1) << "GLX_ARB_create_context_robustness supported.";
attribs.push_back(GLX_CONTEXT_RESET_NOTIFICATION_STRATEGY_ARB);
« no previous file with comments | « gpu/config/gpu_info_collector.cc ('k') | ui/gl/gl_context_x11.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698