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

Unified Diff: cc/scheduler_state_machine.h

Issue 11879012: cc: Redraw incomplete frames when new texture uploads finish (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@decouple_draw3b
Patch Set: rename some method, only check for incomplete frames when impl-side painting 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 side-by-side diff with in-line comments
Download patch
Index: cc/scheduler_state_machine.h
diff --git a/cc/scheduler_state_machine.h b/cc/scheduler_state_machine.h
index 5959bff343e4c17d33026f96eba7c771c79626c4..c9e79442017307452d2d8d275faea8cd5583a9fe 100644
--- a/cc/scheduler_state_machine.h
+++ b/cc/scheduler_state_machine.h
@@ -60,6 +60,7 @@ public:
ACTION_NONE,
ACTION_BEGIN_FRAME,
ACTION_COMMIT,
+ ACTION_CHECK_FOR_NEW_TEXTURES,
ACTION_ACTIVATE_PENDING_TREE_IF_NEEDED,
ACTION_DRAW_IF_POSSIBLE,
ACTION_DRAW_FORCED,
@@ -89,6 +90,10 @@ public:
// we are not visible.
void setNeedsForcedRedraw();
+ // Indicates that a redraw is required because we are currently rendererd
+ // with a low resolution or checkerboarded tile.
+ void didSwapUseIncompleteTexture();
+
// Indicates whether ACTION_DRAW_IF_POSSIBLE drew to the screen or not.
void didDrawIfPossibleCompleted(bool success);
@@ -148,8 +153,10 @@ protected:
bool shouldDraw() const;
bool shouldAttemptTreeActivation() const;
bool shouldAcquireLayerTexturesForMainThread() const;
+ bool shouldCheckForNewTextures() const;
bool hasDrawnThisFrame() const;
bool hasAttemptedTreeActivationThisFrame() const;
+ bool hasCheckedForNewTexturesThisFrame() const;
const SchedulerSettings m_settings;
@@ -158,9 +165,11 @@ protected:
int m_currentFrameNumber;
int m_lastFrameNumberWhereDrawWasCalled;
int m_lastFrameNumberWhereTreeActivationAttempted;
+ int m_lastFrameNumberWhereCheckForNewTexturesCalled;
int m_consecutiveFailedDraws;
int m_maximumNumberOfFailedDrawsBeforeDrawIsForced;
bool m_needsRedraw;
+ bool m_swapUsedIncompleteTexture;
bool m_needsForcedRedraw;
bool m_needsForcedRedrawAfterNextCommit;
bool m_needsCommit;
« cc/scheduler.h ('K') | « cc/scheduler.cc ('k') | cc/scheduler_state_machine.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698