summaryrefslogtreecommitdiffstats
path: root/chrome/common
diff options
context:
space:
mode:
authorapatrick@chromium.org <apatrick@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-02-09 23:28:43 +0000
committerapatrick@chromium.org <apatrick@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-02-09 23:28:43 +0000
commitcd189bdbe4ad339765549b41530b59c51973d2cf (patch)
treeebb322b7c0004526cf77f0ac44df5734015e9cab /chrome/common
parentd1015f1c5bc276109b62280694ec180e62ae909f (diff)
downloadchromium_src-cd189bdbe4ad339765549b41530b59c51973d2cf.zip
chromium_src-cd189bdbe4ad339765549b41530b59c51973d2cf.tar.gz
chromium_src-cd189bdbe4ad339765549b41530b59c51973d2cf.tar.bz2
Implemented async flushes for Pepper 3D.
Added waitForProgress field to NPDeviceContext3D to select between a flush (that pushes more work to the GPU process and waits for at least some of it to have been completed) and getting the current state as quickly as possible. The previous method of checking to see if the put offset had advanced was incorrect. TEST=trybots BUG=none Review URL: http://codereview.chromium.org/561058 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@38540 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/common')
-rw-r--r--chrome/common/command_buffer_messages_internal.h20
1 files changed, 17 insertions, 3 deletions
diff --git a/chrome/common/command_buffer_messages_internal.h b/chrome/common/command_buffer_messages_internal.h
index f6fb423..0969f1c 100644
--- a/chrome/common/command_buffer_messages_internal.h
+++ b/chrome/common/command_buffer_messages_internal.h
@@ -13,17 +13,31 @@ IPC_BEGIN_MESSAGES(CommandBuffer)
int32 /* size */,
base::SharedMemoryHandle /* ring_buffer */)
- // Get the current state of the command buffer, optionally reseting the
- // parse error.
+ // Get the current state of the command buffer.
IPC_SYNC_MESSAGE_ROUTED0_1(CommandBufferMsg_GetState,
gpu::CommandBuffer::State /* state */)
+ // Get the current state of the command buffer asynchronously. State is
+ // returned via UpdateState message.
+ IPC_MESSAGE_ROUTED0(CommandBufferMsg_AsyncGetState)
+
// Synchronize the put and get offsets of both processes. Caller passes its
- // current put offset. Current get offset is returned.
+ // current put offset. Current state (including get offset) is returned.
IPC_SYNC_MESSAGE_ROUTED1_1(CommandBufferMsg_Flush,
int32 /* put_offset */,
gpu::CommandBuffer::State /* state */)
+ // Asynchronously synchronize the put and get offsets of both processes.
+ // Caller passes its current put offset. Current state (including get offset)
+ // is returned via an UpdateState message.
+ IPC_MESSAGE_ROUTED1(CommandBufferMsg_AsyncFlush,
+ int32 /* put_offset */)
+
+ // Return the current state of the command buffer following a request via
+ // an AsyncGetState or AsyncFlush message.
+ IPC_MESSAGE_ROUTED1(CommandBufferMsg_UpdateState,
+ gpu::CommandBuffer::State /* state */)
+
// Create a shared memory transfer buffer. Returns an id that can be used to
// identify the transfer buffer from a comment.
IPC_SYNC_MESSAGE_ROUTED1_1(CommandBufferMsg_CreateTransferBuffer,