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

Unified Diff: content/browser/renderer_host/render_widget_host_view_aura.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/render_widget_host_view_aura.cc
diff --git a/content/browser/renderer_host/render_widget_host_view_aura.cc b/content/browser/renderer_host/render_widget_host_view_aura.cc
index c81379835e52682f803a3a864406fa751b442682..0f0db4487705602e0f2034a8c79ded45eed12587 100644
--- a/content/browser/renderer_host/render_widget_host_view_aura.cc
+++ b/content/browser/renderer_host/render_widget_host_view_aura.cc
@@ -1445,9 +1445,11 @@ void RenderWidgetHostViewAura::AcceleratedSurfaceBuffersSwapped(
params_in_pixel.route_id,
gpu_host_id,
params_in_pixel.mailbox_name);
- BuffersSwapped(
- params_in_pixel.size, params_in_pixel.scale_factor,
- params_in_pixel.mailbox_name, ack_callback);
+ BuffersSwapped(params_in_pixel.size,
+ params_in_pixel.scale_factor,
+ params_in_pixel.mailbox_name,
+ params_in_pixel.latency_info,
+ ack_callback);
}
void RenderWidgetHostViewAura::SwapDelegatedFrame(
@@ -1587,9 +1589,11 @@ void RenderWidgetHostViewAura::OnSwapCompositorFrame(
std::string mailbox_name(
reinterpret_cast<const char*>(frame->gl_frame_data->mailbox.name),
sizeof(frame->gl_frame_data->mailbox.name));
- BuffersSwapped(
- frame->gl_frame_data->size, frame->metadata.device_scale_factor,
- mailbox_name, ack_callback);
+ BuffersSwapped(frame->gl_frame_data->size,
+ frame->metadata.device_scale_factor,
+ mailbox_name,
+ frame->metadata.latency_info,
+ ack_callback);
}
#if defined(OS_WIN)
@@ -1606,6 +1610,7 @@ void RenderWidgetHostViewAura::BuffersSwapped(
const gfx::Size& size,
float surface_scale_factor,
const std::string& mailbox_name,
+ const ui::LatencyInfo& latency_info,
const BufferPresentedCallback& ack_callback) {
scoped_refptr<ui::Texture> texture_to_return(current_surface_);
const gfx::Rect surface_rect = gfx::Rect(size);
@@ -1621,6 +1626,7 @@ void RenderWidgetHostViewAura::BuffersSwapped(
if (compositor) {
gfx::Size surface_size = ConvertSizeToDIP(surface_scale_factor, size);
window_->SchedulePaintInRect(gfx::Rect(surface_size));
+ compositor->SetLatencyInfo(latency_info);
}
if (paint_observer_)
@@ -1695,6 +1701,7 @@ void RenderWidgetHostViewAura::AcceleratedSurfacePostSubBuffer(
if (paint_observer_)
paint_observer_->OnUpdateCompositorContent();
window_->SchedulePaintInRect(rect_to_paint);
+ compositor->SetLatencyInfo(params_in_pixel.latency_info);
}
SwapBuffersCompleted(ack_callback, previous_texture);

Powered by Google App Engine
This is Rietveld 408576698