Chromium Code Reviews

Unified Diff: gpu/command_buffer/service/command_buffer_service.cc

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: review comments Created 9 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Index: gpu/command_buffer/service/command_buffer_service.cc
diff --git a/gpu/command_buffer/service/command_buffer_service.cc b/gpu/command_buffer/service/command_buffer_service.cc
index fd443f2e9d341b73d5701f7956d5e5d4de5e05d6..c2a85affc6b361231062a971edf0665f4541a991 100644
--- a/gpu/command_buffer/service/command_buffer_service.cc
+++ b/gpu/command_buffer/service/command_buffer_service.cc
@@ -77,7 +77,7 @@ CommandBufferService::State CommandBufferService::GetState() {
return state;
}
-CommandBufferService::State CommandBufferService::Flush(int32 put_offset) {
+CommandBufferService::State CommandBufferService::FlushSync(int32 put_offset) {
if (put_offset < 0 || put_offset > num_entries_) {
error_ = gpu::error::kOutOfBounds;
return GetState();
@@ -92,6 +92,10 @@ CommandBufferService::State CommandBufferService::Flush(int32 put_offset) {
return GetState();
}
+void CommandBufferService::Flush(int32 put_offset) {
+ FlushSync(put_offset);
+}
+
void CommandBufferService::SetGetOffset(int32 get_offset) {
DCHECK(get_offset >= 0 && get_offset < num_entries_);
get_offset_ = get_offset;

Powered by Google App Engine