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

Unified Diff: gpu/command_buffer/service/image_factory.h

Issue 1269503007: Unify graphics buffer format & usage enums for GpuMemoryBuffer & SurfaceFactoryOzone (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: add header to BUILD.gn Created 5 years, 4 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
« no previous file with comments | « gpu/command_buffer/client/gpu_memory_buffer_manager.h ('k') | gpu/command_buffer/service/image_factory.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gpu/command_buffer/service/image_factory.h
diff --git a/gpu/command_buffer/service/image_factory.h b/gpu/command_buffer/service/image_factory.h
index b5813421945636813d2e72aecb775420bfa9953e..f1ff1936d0ee75afa386b7d637abfad72dc68563 100644
--- a/gpu/command_buffer/service/image_factory.h
+++ b/gpu/command_buffer/service/image_factory.h
@@ -23,28 +23,27 @@ class GPU_EXPORT ImageFactory {
// Returns a valid GpuMemoryBuffer format given a valid internalformat as
// defined by CHROMIUM_gpu_memory_buffer_image.
- static gfx::GpuMemoryBuffer::Format ImageFormatToGpuMemoryBufferFormat(
+ static gfx::BufferFormat ImageFormatToGpuMemoryBufferFormat(
unsigned internalformat);
// Returns a valid GpuMemoryBuffer usage given a valid usage as defined by
// CHROMIUM_gpu_memory_buffer_image.
- static gfx::GpuMemoryBuffer::Usage ImageUsageToGpuMemoryBufferUsage(
- unsigned usage);
+ static gfx::BufferUsage ImageUsageToGpuMemoryBufferUsage(unsigned usage);
// Returns true if |internalformat| is compatible with |format|.
static bool IsImageFormatCompatibleWithGpuMemoryBufferFormat(
unsigned internalformat,
- gfx::GpuMemoryBuffer::Format format);
+ gfx::BufferFormat format);
// Returns true if |format| is supported by |capabilities|.
static bool IsGpuMemoryBufferFormatSupported(
- gfx::GpuMemoryBuffer::Format format,
+ gfx::BufferFormat format,
const Capabilities& capabilities);
// Returns true if |size| is valid for |format|.
static bool IsImageSizeValidForGpuMemoryBufferFormat(
const gfx::Size& size,
- gfx::GpuMemoryBuffer::Format format);
+ gfx::BufferFormat format);
// Creates a GLImage instance for GPU memory buffer identified by |handle|.
// |client_id| should be set to the client requesting the creation of instance
@@ -52,7 +51,7 @@ class GPU_EXPORT ImageFactory {
virtual scoped_refptr<gfx::GLImage> CreateImageForGpuMemoryBuffer(
const gfx::GpuMemoryBufferHandle& handle,
const gfx::Size& size,
- gfx::GpuMemoryBuffer::Format format,
+ gfx::BufferFormat format,
unsigned internalformat,
int client_id) = 0;
« no previous file with comments | « gpu/command_buffer/client/gpu_memory_buffer_manager.h ('k') | gpu/command_buffer/service/image_factory.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698