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

Unified Diff: ui/gfx/gl/gl_context_cgl.cc

Issue 8342024: Fixed bugs with Pepper 3D under dynamic GPU switching. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 2 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 | « content/renderer/render_widget_fullscreen_pepper.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/gfx/gl/gl_context_cgl.cc
===================================================================
--- ui/gfx/gl/gl_context_cgl.cc (revision 106379)
+++ ui/gfx/gl/gl_context_cgl.cc (working copy)
@@ -26,12 +26,14 @@
GLSurface* compatible_surface, GpuPreference gpu_preference) {
DCHECK(compatible_surface);
- // Ensure the GPU preference is compatible with contexts already in the
- // share group.
GLContextCGL* share_context = share_group() ?
static_cast<GLContextCGL*>(share_group()->GetContext()) : NULL;
- if (share_context && gpu_preference != share_context->GetGpuPreference())
- return false;
+ if (SupportsDualGpus()) {
+ // Ensure the GPU preference is compatible with contexts already in the
+ // share group.
+ if (share_context && gpu_preference != share_context->GetGpuPreference())
+ return false;
+ }
std::vector<CGLPixelFormatAttribute> attribs;
attribs.push_back(kCGLPFAPBuffer);
« no previous file with comments | « content/renderer/render_widget_fullscreen_pepper.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698