Index: ui/gl/gl_context.h |
diff --git a/ui/gl/gl_context.h b/ui/gl/gl_context.h |
index c5d517690fd5a8e0a14cac80a0bed019f91f5c4c..ba921e3d79c03e7ee22aedaac2953ec0669a7267 100644 |
--- a/ui/gl/gl_context.h |
+++ b/ui/gl/gl_context.h |
@@ -198,6 +198,14 @@ class GL_EXPORT GLContextReal : public GLContext { |
DISALLOW_COPY_AND_ASSIGN(GLContextReal); |
}; |
+// Wraps GLContext in scoped_refptr and tries to initializes it. Returns a |
+// scoped_refptr containing the initialized GLContext or nullptr if |
+// initialization fails. |
+GL_EXPORT scoped_refptr<GLContext> InitializeGLContext( |
+ scoped_refptr<GLContext> context, |
+ GLSurface* compatible_surface, |
+ GpuPreference gpu_preference); |
+ |
} // namespace gl |
#endif // UI_GL_GL_CONTEXT_H_ |