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

Unified Diff: gpu/command_buffer/client/cmd_buffer_helper.h

Issue 6316002: Make CommandBuffer::Flush asynchronous, and add CommandBuffer::FlushSync with former semantics. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 9 years, 11 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 | « chrome/renderer/webplugin_delegate_pepper.cc ('k') | gpu/command_buffer/client/cmd_buffer_helper.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gpu/command_buffer/client/cmd_buffer_helper.h
diff --git a/gpu/command_buffer/client/cmd_buffer_helper.h b/gpu/command_buffer/client/cmd_buffer_helper.h
index d174831ec95d19043e976a022577ff4813515254..c28333aab8d7d96e729ea5ccc6559e02324e8ee1 100644
--- a/gpu/command_buffer/client/cmd_buffer_helper.h
+++ b/gpu/command_buffer/client/cmd_buffer_helper.h
@@ -42,13 +42,18 @@ class CommandBufferHelper {
// buffer.
bool Initialize(int32 ring_buffer_size);
+ // Asynchronously flushes the commands, setting the put pointer to let the
+ // buffer interface know that new commands have been added. After a flush
+ // returns, the command buffer service is aware of all pending commands.
+ void Flush();
+
// Flushes the commands, setting the put pointer to let the buffer interface
// know that new commands have been added. After a flush returns, the command
// buffer service is aware of all pending commands and it is guaranteed to
// have made some progress in processing them. Returns whether the flush was
// successful. The flush will fail if the command buffer service has
// disconnected.
- bool Flush();
+ bool FlushSync();
// Waits until all the commands have been executed. Returns whether it
// was successful. The function will fail if the command buffer service has
@@ -225,6 +230,7 @@ class CommandBufferHelper {
int32 last_token_read_;
int32 get_;
int32 put_;
+ int32 last_put_sent_;
friend class CommandBufferHelperTest;
DISALLOW_COPY_AND_ASSIGN(CommandBufferHelper);
« no previous file with comments | « chrome/renderer/webplugin_delegate_pepper.cc ('k') | gpu/command_buffer/client/cmd_buffer_helper.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698