summaryrefslogtreecommitdiffstats
path: root/ui/gfx/surface
diff options
context:
space:
mode:
authorrsesek@chromium.org <rsesek@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-05-31 21:53:38 +0000
committerrsesek@chromium.org <rsesek@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-05-31 21:53:38 +0000
commit0b7a2fff445beb2c5de1e2a632540a4107e00708 (patch)
tree759f7a9d489b6bf44c9f5de081d7bf335233028d /ui/gfx/surface
parent72ab1b792dbddfb680490153984b1865b725d8f4 (diff)
downloadchromium_src-0b7a2fff445beb2c5de1e2a632540a4107e00708.zip
chromium_src-0b7a2fff445beb2c5de1e2a632540a4107e00708.tar.gz
chromium_src-0b7a2fff445beb2c5de1e2a632540a4107e00708.tar.bz2
Revert 87371 - Broke Compile - Support for glSetSurfaceCHROMIUM.
This command allows a previously created GPU surface to be made current for a command buffer. There are no surfaces registered at this point so this command is currently a no-op. Review URL: http://codereview.chromium.org/7077001 TBR=apatrick@chromium.org Review URL: http://codereview.chromium.org/7027008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@87373 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ui/gfx/surface')
-rw-r--r--ui/gfx/surface/accelerated_surface_mac.cc10
-rw-r--r--ui/gfx/surface/accelerated_surface_mac.h4
2 files changed, 7 insertions, 7 deletions
diff --git a/ui/gfx/surface/accelerated_surface_mac.cc b/ui/gfx/surface/accelerated_surface_mac.cc
index ce2f7a0..a749c46 100644
--- a/ui/gfx/surface/accelerated_surface_mac.cc
+++ b/ui/gfx/surface/accelerated_surface_mac.cc
@@ -35,14 +35,14 @@ bool AcceleratedSurface::Initialize(gfx::GLContext* share_context,
if (gfx::GetGLImplementation() != gfx::kGLImplementationDesktopGL)
return false;
- gl_surface_ = gfx::GLSurface::CreateOffscreenGLSurface(gfx::Size(1, 1));
+ gl_surface_.reset(gfx::GLSurface::CreateOffscreenGLSurface(gfx::Size(1, 1)));
if (!gl_surface_.get()) {
Destroy();
return false;
}
- gl_context_ = gfx::GLContext::CreateGLContext(share_context,
- gl_surface_.get());
+ gl_context_.reset(gfx::GLContext::CreateGLContext(share_context,
+ gl_surface_.get()));
if (!gl_context_.get()) {
Destroy();
return false;
@@ -66,8 +66,8 @@ void AcceleratedSurface::Destroy() {
}
transport_dib_.reset();
- gl_context_ = NULL;
- gl_surface_ = NULL;
+ gl_context_.reset();
+ gl_surface_.reset();
}
// Call after making changes to the surface which require a visual update.
diff --git a/ui/gfx/surface/accelerated_surface_mac.h b/ui/gfx/surface/accelerated_surface_mac.h
index d9ee833..13bec9b 100644
--- a/ui/gfx/surface/accelerated_surface_mac.h
+++ b/ui/gfx/surface/accelerated_surface_mac.h
@@ -129,8 +129,8 @@ class AcceleratedSurface {
// speaking, we do not need to allocate a GL context all of the
// time. We only need one if (a) we are using the IOSurface code
// path, or (b) if we are allocating an FBO internally.
- scoped_refptr<gfx::GLSurface> gl_surface_;
- scoped_refptr<gfx::GLContext> gl_context_;
+ scoped_ptr<gfx::GLSurface> gl_surface_;
+ scoped_ptr<gfx::GLContext> gl_context_;
// Either |io_surface_| or |transport_dib_| is a valid pointer, but not both.
// |io_surface_| is non-NULL if the IOSurface APIs are supported (Mac OS X
// 10.6 and later).