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

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

Issue 1389133002: content: Use type-parameterized tests for GpuMemoryBuffer implementations. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: add blankline Created 5 years, 2 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.h
diff --git a/content/common/gpu/client/gpu_memory_buffer_impl_io_surface.h b/content/common/gpu/client/gpu_memory_buffer_impl_io_surface.h
index d2249386dec1c6e4a72789bdc17306e88518e775..d75c9d1e7fa8a56bc0f9fc94cc552d04d42b9066 100644
--- a/content/common/gpu/client/gpu_memory_buffer_impl_io_surface.h
+++ b/content/common/gpu/client/gpu_memory_buffer_impl_io_surface.h
@@ -8,20 +8,31 @@
#include <IOSurface/IOSurface.h>
#include "base/mac/scoped_cftyperef.h"
+#include "content/common/content_export.h"
#include "content/common/gpu/client/gpu_memory_buffer_impl.h"
namespace content {
// Implementation of GPU memory buffer based on IO surfaces.
-class GpuMemoryBufferImplIOSurface : public GpuMemoryBufferImpl {
+class CONTENT_EXPORT GpuMemoryBufferImplIOSurface : public GpuMemoryBufferImpl {
public:
- static scoped_ptr<GpuMemoryBufferImpl> CreateFromHandle(
+ ~GpuMemoryBufferImplIOSurface() override;
+
+ static scoped_ptr<GpuMemoryBufferImplIOSurface> CreateFromHandle(
const gfx::GpuMemoryBufferHandle& handle,
const gfx::Size& size,
gfx::BufferFormat format,
gfx::BufferUsage usage,
const DestructionCallback& callback);
+ static bool IsConfigurationSupported(gfx::BufferFormat format,
+ gfx::BufferUsage usage);
+
+ static base::Closure AllocateForTesting(const gfx::Size& size,
+ gfx::BufferFormat format,
+ gfx::BufferUsage usage,
+ gfx::GpuMemoryBufferHandle* handle);
+
// Overridden from gfx::GpuMemoryBuffer:
bool Map(void** data) override;
void Unmap() override;
@@ -35,7 +46,6 @@ class GpuMemoryBufferImplIOSurface : public GpuMemoryBufferImpl {
const DestructionCallback& callback,
IOSurfaceRef io_surface,
uint32_t lock_flags);
- ~GpuMemoryBufferImplIOSurface() override;
base::ScopedCFTypeRef<IOSurfaceRef> io_surface_;
uint32_t lock_flags_;
« no previous file with comments | « content/common/gpu/client/gpu_memory_buffer_impl.cc ('k') | content/common/gpu/client/gpu_memory_buffer_impl_io_surface.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698