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

Unified Diff: content/common/gpu/gpu_command_buffer_stub.h

Issue 12614013: Plumb cc::LatencyInfo through command buffer and output surface (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 8 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
Index: content/common/gpu/gpu_command_buffer_stub.h
diff --git a/content/common/gpu/gpu_command_buffer_stub.h b/content/common/gpu/gpu_command_buffer_stub.h
index d39385019d084a2a41eec3401bffefcc8f4e75b3..4ff2237cc18877d58f5cc004319c0dd8da69e43f 100644
--- a/content/common/gpu/gpu_command_buffer_stub.h
+++ b/content/common/gpu/gpu_command_buffer_stub.h
@@ -12,6 +12,7 @@
#include "base/memory/scoped_vector.h"
#include "base/memory/weak_ptr.h"
#include "base/observer_list.h"
+#include "cc/debug/latency_info.h"
#include "content/common/content_export.h"
#include "content/common/gpu/gpu_memory_allocation.h"
#include "content/common/gpu/gpu_memory_manager.h"
@@ -58,6 +59,9 @@ class GpuCommandBufferStub
virtual ~DestructionObserver() {}
};
+ typedef base::Callback<void(const cc::LatencyInfo&)>
+ LatencyInfoCallback;
+
GpuCommandBufferStub(
GpuChannel* channel,
GpuCommandBufferStub* share_group,
@@ -131,6 +135,8 @@ class GpuCommandBufferStub
void SetPreemptByFlag(scoped_refptr<gpu::PreemptionFlag> flag);
+ void SetLatencyInfoCallback(const LatencyInfoCallback& callback);
+
private:
GpuMemoryManager* GetMemoryManager();
bool MakeCurrent();
@@ -177,6 +183,7 @@ class GpuCommandBufferStub
void OnCommandProcessed();
void OnParseError();
+ void OnSetLatencyInfo(const cc::LatencyInfo& latency_info);
void ReportState();
@@ -245,6 +252,8 @@ class GpuCommandBufferStub
scoped_refptr<gpu::PreemptionFlag> preemption_flag_;
+ LatencyInfoCallback latency_info_callback_;
+
GURL active_url_;
size_t active_url_hash_;
« no previous file with comments | « content/common/gpu/client/command_buffer_proxy_impl.cc ('k') | content/common/gpu/gpu_command_buffer_stub.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698