diff options
Diffstat (limited to 'webkit/gpu/webgraphicscontext3d_in_process_impl.cc')
-rw-r--r-- | webkit/gpu/webgraphicscontext3d_in_process_impl.cc | 17 |
1 files changed, 5 insertions, 12 deletions
diff --git a/webkit/gpu/webgraphicscontext3d_in_process_impl.cc b/webkit/gpu/webgraphicscontext3d_in_process_impl.cc index 08d93ca..2fb703a 100644 --- a/webkit/gpu/webgraphicscontext3d_in_process_impl.cc +++ b/webkit/gpu/webgraphicscontext3d_in_process_impl.cc @@ -17,7 +17,6 @@ #include "ui/gfx/gl/gl_bindings_skia_in_process.h" #include "ui/gfx/gl/gl_context.h" #include "ui/gfx/gl/gl_implementation.h" -#include "ui/gfx/gl/gl_surface.h" namespace webkit { namespace gpu { @@ -103,7 +102,7 @@ bool WebGraphicsContext3DInProcessImpl::initialize( WebGraphicsContext3D::Attributes attributes, WebView* webView, bool render_directly_to_web_view) { - if (!gfx::GLSurface::InitializeOneOff()) + if (!gfx::GLContext::InitializeOneOff()) return false; gfx::BindSkiaToInProcessGL(); @@ -133,9 +132,8 @@ bool WebGraphicsContext3DInProcessImpl::initialize( // and from there to the window, and WebViewImpl::paint already // correctly handles the case where the compositor is active but // the output needs to go to a WebCanvas. - scoped_ptr<gfx::GLSurface> surface(gfx::GLSurface::CreateOffscreenGLSurface( - gfx::Size(1, 1))); - if (!surface.get()) { + gl_context_.reset(gfx::GLContext::CreateOffscreenGLContext(share_context)); + if (!gl_context_.get()) { if (!is_gles2_) return false; @@ -147,16 +145,11 @@ bool WebGraphicsContext3DInProcessImpl::initialize( // and force them to drop their contexts, sending a context lost event if // necessary. webView->mainFrame()->collectGarbage(); - surface.reset(gfx::GLSurface::CreateOffscreenGLSurface(gfx::Size(1, 1))); - if (!surface.get()) + gl_context_.reset(gfx::GLContext::CreateOffscreenGLContext(share_context)); + if (!gl_context_.get()) return false; } - gl_context_.reset(gfx::GLContext::CreateGLContext(surface.release(), - share_context)); - if (!gl_context_.get()) - return false; - attributes_ = attributes; // FIXME: for the moment we disable multisampling for the compositor. |