Index: ui/gl/gpu_switching_manager.h |
=================================================================== |
--- ui/gl/gpu_switching_manager.h (revision 158081) |
+++ ui/gl/gpu_switching_manager.h (working copy) |
@@ -8,6 +8,9 @@ |
#include <vector> |
#include "base/memory/singleton.h" |
+#if defined(OS_MACOSX) |
+#include "ui/gl/gl_context_cgl.h" |
+#endif // OS_MACOSX |
#include "ui/gl/gl_export.h" |
#include "ui/gl/gpu_preference.h" |
@@ -23,8 +26,13 @@ |
void ForceUseOfIntegratedGpu(); |
void ForceUseOfDiscreteGpu(); |
- // Adjust GpuPreference based on the current switching option. |
- // If none is set, return the original GpuPreference. |
+ // On Mac: |
+ // If no GPU is forced, return the original GpuPreference. |
+ // Otherwise, always return PreferIntegratedGpu. |
Ken Russell (switch to Gerrit)
2012/09/21 23:00:29
I understand why you're returning PreferIntegrated
Zhenyao Mo
2012/09/21 23:08:09
Done.
|
+ // If forcing discrete GPU, we set up a pixel format, which keeps |
+ // Chrome on the discrete GPU throughout the rest of Chrome's lifetime. |
+ // On other platforms: |
+ // Return the original GpuPreference. |
GpuPreference AdjustGpuPreference(GpuPreference gpu_preference); |
private: |