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

Side by Side Diff: cc/trees/single_thread_proxy.cc

Issue 23088002: cc: RenderingStats overhaul (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Merged EnumerateFileds. Created 7 years, 4 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 unified diff | Download patch
« no previous file with comments | « cc/trees/layer_tree_host_impl.cc ('k') | cc/trees/thread_proxy.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2011 The Chromium Authors. All rights reserved. 1 // Copyright 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "cc/trees/single_thread_proxy.h" 5 #include "cc/trees/single_thread_proxy.h"
6 6
7 #include "base/auto_reset.h" 7 #include "base/auto_reset.h"
8 #include "base/debug/trace_event.h" 8 #include "base/debug/trace_event.h"
9 #include "cc/output/context_provider.h" 9 #include "cc/output/context_provider.h"
10 #include "cc/output/output_surface.h" 10 #include "cc/output/output_surface.h"
(...skipping 203 matching lines...) Expand 10 before | Expand all | Expand 10 after
214 // In the single-threaded case, the scale and scroll deltas should never be 214 // In the single-threaded case, the scale and scroll deltas should never be
215 // touched on the impl layer tree. 215 // touched on the impl layer tree.
216 scoped_ptr<ScrollAndScaleSet> scroll_info = 216 scoped_ptr<ScrollAndScaleSet> scroll_info =
217 layer_tree_host_impl_->ProcessScrollDeltas(); 217 layer_tree_host_impl_->ProcessScrollDeltas();
218 DCHECK(!scroll_info->scrolls.size()); 218 DCHECK(!scroll_info->scrolls.size());
219 DCHECK_EQ(1.f, scroll_info->page_scale_delta); 219 DCHECK_EQ(1.f, scroll_info->page_scale_delta);
220 #endif 220 #endif
221 221
222 base::TimeDelta duration = stats_instrumentation->EndRecording(start_time); 222 base::TimeDelta duration = stats_instrumentation->EndRecording(start_time);
223 stats_instrumentation->AddCommit(duration); 223 stats_instrumentation->AddCommit(duration);
224 stats_instrumentation->AccumulateAndClearMainThreadStats();
224 } 225 }
225 layer_tree_host_->CommitComplete(); 226 layer_tree_host_->CommitComplete();
226 next_frame_is_newly_committed_frame_ = true; 227 next_frame_is_newly_committed_frame_ = true;
227 } 228 }
228 229
229 void SingleThreadProxy::SetNeedsCommit() { 230 void SingleThreadProxy::SetNeedsCommit() {
230 DCHECK(Proxy::IsMainThread()); 231 DCHECK(Proxy::IsMainThread());
231 layer_tree_host_->ScheduleComposite(); 232 layer_tree_host_->ScheduleComposite();
232 } 233 }
233 234
(...skipping 255 matching lines...) Expand 10 before | Expand all | Expand 10 after
489 void SingleThreadProxy::DidSwapFrame() { 490 void SingleThreadProxy::DidSwapFrame() {
490 if (next_frame_is_newly_committed_frame_) { 491 if (next_frame_is_newly_committed_frame_) {
491 next_frame_is_newly_committed_frame_ = false; 492 next_frame_is_newly_committed_frame_ = false;
492 layer_tree_host_->DidCommitAndDrawFrame(); 493 layer_tree_host_->DidCommitAndDrawFrame();
493 } 494 }
494 } 495 }
495 496
496 bool SingleThreadProxy::CommitPendingForTesting() { return false; } 497 bool SingleThreadProxy::CommitPendingForTesting() { return false; }
497 498
498 } // namespace cc 499 } // namespace cc
OLDNEW
« no previous file with comments | « cc/trees/layer_tree_host_impl.cc ('k') | cc/trees/thread_proxy.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698