Chromium Code Reviews| Index: content/common/gpu/client/command_buffer_proxy.h |
| diff --git a/content/common/gpu/client/command_buffer_proxy.h b/content/common/gpu/client/command_buffer_proxy.h |
| index 398f7942de564500cbb2c8cf3f24e2c11f01df0f..37cbe7cb1724e1e94de76a8360bccca086946438 100644 |
| --- a/content/common/gpu/client/command_buffer_proxy.h |
| +++ b/content/common/gpu/client/command_buffer_proxy.h |
| @@ -18,6 +18,7 @@ |
| #include "base/memory/weak_ptr.h" |
| #include "content/common/gpu/client/gpu_video_decode_accelerator_host.h" |
| #include "gpu/command_buffer/common/command_buffer.h" |
| +#include "gpu/command_buffer/common/command_buffer_shared.h" |
| #include "ipc/ipc_channel.h" |
| #include "ipc/ipc_message.h" |
| @@ -116,6 +117,9 @@ class CommandBufferProxy : public gpu::CommandBuffer, |
| void OnEchoAck(); |
| void OnConsoleMessage(const GPUCommandBufferConsoleMessage& message); |
| + // Try to read an updated copy of the state from shared memory. |
| + void TryUpdateState(); |
| + |
| // Local cache of id to transfer buffer mapping. |
| typedef std::map<int32, gpu::Buffer> TransferBufferMap; |
| TransferBufferMap transfer_buffers_; |
| @@ -128,6 +132,9 @@ class CommandBufferProxy : public gpu::CommandBuffer, |
| // The last cached state received from the service. |
| State last_state_; |
|
apatrick_chromium
2012/02/13 20:50:58
Do we need to have two copied of the shared state?
|
| + // The shared memory area used to update state. |
| + gpu::CommandBufferSharedState* shared_state_; |
| + |
| // |*this| is owned by |*channel_| and so is always outlived by it, so using a |
| // raw pointer is ok. |
| GpuChannelHost* channel_; |