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

Unified Diff: cc/scheduler/scheduler_state_machine.cc

Issue 221833009: cc: Move scheduling logic out of OutputSurface (Closed) Base URL: http://git.chromium.org/chromium/src.git@swapAck2Sched11
Patch Set: rebase; add comment about race Created 6 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
« no previous file with comments | « cc/scheduler/scheduler_settings.cc ('k') | cc/scheduler/scheduler_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/scheduler/scheduler_state_machine.cc
diff --git a/cc/scheduler/scheduler_state_machine.cc b/cc/scheduler/scheduler_state_machine.cc
index 7b2bb438e7c861478d7227475182a4e59df0d126..647af71e27b91ebf66a6487ab78e7fe1c6470329 100644
--- a/cc/scheduler/scheduler_state_machine.cc
+++ b/cc/scheduler/scheduler_state_machine.cc
@@ -801,10 +801,13 @@ bool SchedulerStateMachine::ShouldPollForAnticipatedDrawTriggers() const {
return false;
}
+// Note: If SupportsProactiveBeginFrame is false, the scheduler should poll
+// for changes in it's draw state so it can request a BeginFrame when it's
+// actually ready.
bool SchedulerStateMachine::SupportsProactiveBeginFrame() const {
- // Both the synchronous compositor and disabled vsync settings
- // make it undesirable to proactively request BeginImplFrames.
- // If this is true, the scheduler should poll.
+ // It is undesirable to proactively request BeginFrames if we are
+ // using a synchronous compositor because we *must* draw for every
+ // BeginFrame, which could cause duplicate draws.
return !settings_.using_synchronous_renderer_compositor;
}
« no previous file with comments | « cc/scheduler/scheduler_settings.cc ('k') | cc/scheduler/scheduler_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698