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

Side by Side Diff: cc/scheduler_state_machine.cc

Issue 11830040: cc: Do not request redraw on commit when impl-side painting (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@decouple_draw3
Patch Set: Created 7 years, 11 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 | « no previous file | cc/thread_proxy.cc » ('j') | cc/thread_proxy.cc » ('J')
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/scheduler_state_machine.h" 5 #include "cc/scheduler_state_machine.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "base/stringprintf.h" 8 #include "base/stringprintf.h"
9 9
10 namespace cc { 10 namespace cc {
(...skipping 167 matching lines...) Expand 10 before | Expand all | Expand 10 after
178 m_commitState = COMMIT_STATE_FRAME_IN_PROGRESS; 178 m_commitState = COMMIT_STATE_FRAME_IN_PROGRESS;
179 m_needsCommit = false; 179 m_needsCommit = false;
180 m_needsForcedCommit = false; 180 m_needsForcedCommit = false;
181 return; 181 return;
182 182
183 case ACTION_COMMIT: 183 case ACTION_COMMIT:
184 if (m_expectImmediateBeginFrame) 184 if (m_expectImmediateBeginFrame)
185 m_commitState = COMMIT_STATE_WAITING_FOR_FIRST_FORCED_DRAW; 185 m_commitState = COMMIT_STATE_WAITING_FOR_FIRST_FORCED_DRAW;
186 else 186 else
187 m_commitState = COMMIT_STATE_WAITING_FOR_FIRST_DRAW; 187 m_commitState = COMMIT_STATE_WAITING_FOR_FIRST_DRAW;
188 m_needsRedraw = true;
nduca 2013/01/10 11:01:09 this seems really funky
189 if (m_drawIfPossibleFailed) 188 if (m_drawIfPossibleFailed)
190 m_lastFrameNumberWhereDrawWasCalled = -1; 189 m_lastFrameNumberWhereDrawWasCalled = -1;
191 190
192 if (m_needsForcedRedrawAfterNextCommit) { 191 if (m_needsForcedRedrawAfterNextCommit) {
193 m_needsForcedRedrawAfterNextCommit = false; 192 m_needsForcedRedrawAfterNextCommit = false;
194 m_needsForcedRedraw = true; 193 m_needsForcedRedraw = true;
195 } 194 }
196 195
197 m_textureState = LAYER_TEXTURE_STATE_ACQUIRED_BY_IMPL_THREAD; 196 m_textureState = LAYER_TEXTURE_STATE_ACQUIRED_BY_IMPL_THREAD;
198 return; 197 return;
(...skipping 149 matching lines...) Expand 10 before | Expand all | Expand 10 after
348 m_outputSurfaceState = OUTPUT_SURFACE_ACTIVE; 347 m_outputSurfaceState = OUTPUT_SURFACE_ACTIVE;
349 setNeedsCommit(); 348 setNeedsCommit();
350 } 349 }
351 350
352 void SchedulerStateMachine::setMaximumNumberOfFailedDrawsBeforeDrawIsForced(int numDraws) 351 void SchedulerStateMachine::setMaximumNumberOfFailedDrawsBeforeDrawIsForced(int numDraws)
353 { 352 {
354 m_maximumNumberOfFailedDrawsBeforeDrawIsForced = numDraws; 353 m_maximumNumberOfFailedDrawsBeforeDrawIsForced = numDraws;
355 } 354 }
356 355
357 } // namespace cc 356 } // namespace cc
OLDNEW
« no previous file with comments | « no previous file | cc/thread_proxy.cc » ('j') | cc/thread_proxy.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698