| Index: ui/gl/gl_context.h
|
| diff --git a/ui/gl/gl_context.h b/ui/gl/gl_context.h
|
| index ebc98faa88667c0317ab0bcb8f8bf107d3458b3d..542940c7683894bb857e311f97bbb53cf0102583 100644
|
| --- a/ui/gl/gl_context.h
|
| +++ b/ui/gl/gl_context.h
|
| @@ -33,6 +33,12 @@ class GPUTiming;
|
| class GPUTimingClient;
|
| struct GLVersionInfo;
|
|
|
| +struct GLContextAttribs {
|
| + GpuPreference gpu_preference = PreferIntegratedGpu;
|
| + bool bind_generates_resource = true;
|
| + bool webgl_compatibility_context = false;
|
| +};
|
| +
|
| // Encapsulates an OpenGL context, hiding platform specific management.
|
| class GL_EXPORT GLContext : public base::RefCounted<GLContext> {
|
| public:
|
| @@ -42,8 +48,8 @@ class GL_EXPORT GLContext : public base::RefCounted<GLContext> {
|
| // context can be made with other surface's of the same type. The compatible
|
| // surface is only needed for certain platforms like WGL, OSMesa and GLX. It
|
| // should be specific for all platforms though.
|
| - virtual bool Initialize(
|
| - GLSurface* compatible_surface, GpuPreference gpu_preference) = 0;
|
| + virtual bool Initialize(GLSurface* compatible_surface,
|
| + const GLContextAttribs& attribs) = 0;
|
|
|
| // Makes the GL context and a surface current on the current thread.
|
| virtual bool MakeCurrent(GLSurface* surface) = 0;
|
| @@ -199,7 +205,7 @@ class GL_EXPORT GLContextReal : public GLContext {
|
| GL_EXPORT scoped_refptr<GLContext> InitializeGLContext(
|
| scoped_refptr<GLContext> context,
|
| GLSurface* compatible_surface,
|
| - GpuPreference gpu_preference);
|
| + const GLContextAttribs& attribs);
|
|
|
| } // namespace gl
|
|
|
|
|