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

Unified Diff: content/browser/renderer_host/image_transport_factory.cc

Issue 15842013: Plumb LatencyInfo through aura. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 7 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/browser/renderer_host/image_transport_factory.cc
diff --git a/content/browser/renderer_host/image_transport_factory.cc b/content/browser/renderer_host/image_transport_factory.cc
index 1e566ac2f1e7d241d09bcf2e36f09a0ee6a4e625..eecbf3feb32a4ccb0a5b3a04497ba0576d52c00b 100644
--- a/content/browser/renderer_host/image_transport_factory.cc
+++ b/content/browser/renderer_host/image_transport_factory.cc
@@ -353,6 +353,29 @@ class BrowserCompositorOutputSurface
compositor_, timebase, interval));
}
+ virtual void SwapBuffers(const ui::LatencyInfo& latency_info) OVERRIDE {
+ WebGraphicsContext3DCommandBufferImpl* command_buffer =
+ static_cast<WebGraphicsContext3DCommandBufferImpl*>(context3d());
+ CommandBufferProxyImpl* command_buffer_proxy =
+ command_buffer->GetCommandBufferProxy();
+ DCHECK(command_buffer_proxy);
+ context3d()->shallowFlushCHROMIUM();
+ command_buffer_proxy->SetLatencyInfo(latency_info);
+ OutputSurface::SwapBuffers(latency_info);
+ }
+
+ virtual void PostSubBuffer(gfx::Rect rect,
+ const ui::LatencyInfo& latency_info) OVERRIDE {
+ WebGraphicsContext3DCommandBufferImpl* command_buffer =
+ static_cast<WebGraphicsContext3DCommandBufferImpl*>(context3d());
+ CommandBufferProxyImpl* command_buffer_proxy =
+ command_buffer->GetCommandBufferProxy();
+ DCHECK(command_buffer_proxy);
+ context3d()->shallowFlushCHROMIUM();
+ command_buffer_proxy->SetLatencyInfo(latency_info);
+ OutputSurface::PostSubBuffer(rect, latency_info);
+ }
+
private:
int surface_id_;
scoped_refptr<BrowserCompositorOutputSurfaceProxy> output_surface_proxy_;
« no previous file with comments | « content/browser/gpu/gpu_process_host_ui_shim.cc ('k') | content/browser/renderer_host/render_widget_host_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698