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

Unified Diff: cc/CCTextureUpdateController.cpp

Issue 10963039: cc: Always try to fill the upload queue. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Created 8 years, 3 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/CCTextureUpdateController.cpp
diff --git a/cc/CCTextureUpdateController.cpp b/cc/CCTextureUpdateController.cpp
index 32923e75bbbb6329eb199926b971ba7b69b96a04..c01c45247fd8c9eb34dc0035f820949aba116c65 100644
--- a/cc/CCTextureUpdateController.cpp
+++ b/cc/CCTextureUpdateController.cpp
@@ -159,9 +159,11 @@ bool CCTextureUpdateController::updateMoreTexturesIfEnoughTimeRemaining()
if (!m_queue->fullUploadSize())
return false;
reveman 2012/09/22 00:50:26 And I think you need to include this in the loop b
- bool hasTimeRemaining = monotonicTimeNow() < m_monotonicTimeLimit - updateMoreTexturesTime();
- if (hasTimeRemaining)
+ double timeRemaining = m_monotonicTimeLimit - monotonicTimeNow();
+ while (timeRemaining > updateMoreTexturesTime() && m_queue->fullUploadSize() && !m_uploader->isBusy()) {
updateMoreTexturesNow();
+ timeRemaining -= updateMoreTexturesTime();
+ }
return true;
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698