Chromium Code Reviews| Index: gpu/command_buffer/common/command_buffer.h |
| diff --git a/gpu/command_buffer/common/command_buffer.h b/gpu/command_buffer/common/command_buffer.h |
| index 3078bca2ba3af97db63fbdd5ecb9da0180d94cbd..080ce7039f78e6f70d597c42dea7ea31137b010d 100644 |
| --- a/gpu/command_buffer/common/command_buffer.h |
| +++ b/gpu/command_buffer/common/command_buffer.h |
| @@ -13,6 +13,11 @@ namespace base { |
| class SharedMemory; |
| } |
| +namespace gfx { |
| +class GLImage; |
| +class GpuMemoryBuffer; |
| +} |
| + |
| namespace gpu { |
| // Common interface for CommandBuffer implementations. |
| @@ -141,6 +146,20 @@ class GPU_EXPORT CommandBuffer { |
| // be used for cross-context synchronization. |
| virtual uint32 InsertSyncPoint() = 0; |
| + // Create a gpu memory buffer of the given dimensions and format. Returns |
|
kaanb
2013/07/31 23:44:05
optional: I prefer using third-person in comments,
reveman
2013/08/01 13:32:18
I prefer to keep it consistent with CreateTransfer
|
| + // its ID or -1 on error. |
| + virtual gfx::GpuMemoryBuffer* CreateGpuMemoryBuffer( |
|
piman
2013/08/01 21:19:30
I would prefer if we didn't load up CommandBuffer
no sievers
2013/08/01 21:30:04
Or can it just go through GpuCommandBufferStub?
We
reveman
2013/08/08 23:19:00
I've limited the CommandBuffer changes to adding C
|
| + size_t width, |
| + size_t height, |
| + unsigned internalformat, |
| + int32* id) = 0; |
| + |
| + // Destroy a gpu memory buffer. The ID must be positive. |
| + virtual void DestroyGpuMemoryBuffer(int32 id) = 0; |
| + |
| + // Get the image associated with an ID. Returns a null image for ID 0. |
| + virtual gfx::GLImage* GetImage(int32 id) = 0; |
| + |
| private: |
| DISALLOW_COPY_AND_ASSIGN(CommandBuffer); |
| }; |