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

Unified Diff: cc/surfaces/surface.cc

Issue 2721763002: SetPreviousFrameSurface should copy latency info to the new surface (Closed)
Patch Set: c Created 3 years, 10 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: cc/surfaces/surface.cc
diff --git a/cc/surfaces/surface.cc b/cc/surfaces/surface.cc
index 63dd62cc1b005c286c2a5c369cbc91aad51a6c77..ab4bdb27d3c74284c7c97a8ec1af534931830c66 100644
--- a/cc/surfaces/surface.cc
+++ b/cc/surfaces/surface.cc
@@ -50,6 +50,13 @@ void Surface::SetPreviousFrameSurface(Surface* surface) {
DCHECK(surface);
frame_index_ = surface->frame_index() + 1;
previous_frame_surface_id_ = surface->surface_id();
+ if (!surface->HasActiveFrame())
+ return;
+ active_frame_->metadata.latency_info.insert(
jbauman 2017/02/28 23:11:09 Also check whether active_frame_ exists for the ne
Fady Samuel 2017/03/01 04:30:56 I actually think that we might want to place the L
Saman Sami 2017/03/01 16:35:20 A frame was just submitted, so either pending or a
+ active_frame_->metadata.latency_info.end(),
+ surface->active_frame_->metadata.latency_info.begin(),
+ surface->active_frame_->metadata.latency_info.end());
+ surface->active_frame_->metadata.latency_info.clear();
}
void Surface::QueueFrame(CompositorFrame frame, const DrawCallback& callback) {

Powered by Google App Engine
This is Rietveld 408576698