Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(63)

Unified Diff: content/common/gpu/client/gpu_memory_buffer_impl_io_surface.cc

Issue 1137453002: content: Pass IOSurface references using Mach IPC. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add MachBrokerTest.IOSurfaces test Created 5 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: content/common/gpu/client/gpu_memory_buffer_impl_io_surface.cc
diff --git a/content/common/gpu/client/gpu_memory_buffer_impl_io_surface.cc b/content/common/gpu/client/gpu_memory_buffer_impl_io_surface.cc
index ed7836c197d43e5a68fb9a8496caf0fbd71742a5..0b8c3aff23140c15fc7f1adb67701733a82a3741 100644
--- a/content/common/gpu/client/gpu_memory_buffer_impl_io_surface.cc
+++ b/content/common/gpu/client/gpu_memory_buffer_impl_io_surface.cc
@@ -5,6 +5,7 @@
#include "content/common/gpu/client/gpu_memory_buffer_impl_io_surface.h"
#include "base/logging.h"
+#include "content/common/mac/io_surface_manager.h"
namespace content {
@@ -27,7 +28,7 @@ scoped_ptr<GpuMemoryBufferImpl> GpuMemoryBufferImplIOSurface::CreateFromHandle(
Format format,
const DestructionCallback& callback) {
base::ScopedCFTypeRef<IOSurfaceRef> io_surface(
- IOSurfaceLookup(handle.io_surface_id));
+ IOSurfaceManager::GetInstance()->AcquireIOSurface(handle.id));
if (!io_surface)
return scoped_ptr<GpuMemoryBufferImpl>();
@@ -57,7 +58,6 @@ gfx::GpuMemoryBufferHandle GpuMemoryBufferImplIOSurface::GetHandle() const {
gfx::GpuMemoryBufferHandle handle;
handle.type = gfx::IO_SURFACE_BUFFER;
handle.id = id_;
- handle.io_surface_id = IOSurfaceGetID(io_surface_);
return handle;
}

Powered by Google App Engine
This is Rietveld 408576698