Index: content/common/gpu/client/command_buffer_proxy_impl.cc |
diff --git a/content/common/gpu/client/command_buffer_proxy_impl.cc b/content/common/gpu/client/command_buffer_proxy_impl.cc |
index b24823a31f7768f1cba428d4a06676bae9c72665..baf77e65a73af8efe60717156b78ee47d56b6a8d 100644 |
--- a/content/common/gpu/client/command_buffer_proxy_impl.cc |
+++ b/content/common/gpu/client/command_buffer_proxy_impl.cc |
@@ -311,6 +311,7 @@ gfx::GpuMemoryBuffer* CommandBufferProxyImpl::CreateGpuMemoryBuffer( |
size_t width, |
size_t height, |
unsigned internalformat, |
+ gfx::GpuMemoryBuffer::Usage usage, |
int32* id) { |
*id = -1; |
@@ -321,9 +322,8 @@ gfx::GpuMemoryBuffer* CommandBufferProxyImpl::CreateGpuMemoryBuffer( |
DCHECK(gpu_memory_buffers_.find(new_id) == gpu_memory_buffers_.end()); |
scoped_ptr<gfx::GpuMemoryBuffer> gpu_memory_buffer( |
- channel_->factory()->AllocateGpuMemoryBuffer(width, |
- height, |
- internalformat)); |
+ channel_->factory()->AllocateGpuMemoryBuffer( |
+ width, height, internalformat, usage)); |
if (!gpu_memory_buffer) |
return NULL; |
@@ -337,13 +337,16 @@ gfx::GpuMemoryBuffer* CommandBufferProxyImpl::CreateGpuMemoryBuffer( |
channel_->ShareGpuMemoryBufferToGpuProcess( |
gpu_memory_buffer->GetHandle()); |
- if (!Send(new GpuCommandBufferMsg_RegisterGpuMemoryBuffer( |
- route_id_, |
- new_id, |
- handle, |
- width, |
- height, |
- internalformat))) { |
+ GpuCommandBufferMsg_RegisterGpuMemoryBuffer_Params params; |
+ params.id = new_id; |
+ params.gpu_memory_buffer = handle; |
+ params.width = width; |
+ params.height = height; |
+ params.internalformat = internalformat; |
+ params.usage = usage; |
+ |
+ if (!Send( |
+ new GpuCommandBufferMsg_RegisterGpuMemoryBuffer(route_id_, params))) { |
return NULL; |
} |