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

Unified Diff: cc/CCThreadProxy.cpp

Issue 10907075: Roll cc snapshot up to 127605 (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
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 | « cc/CCThreadProxy.h ('k') | cc/LayerChromium.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/CCThreadProxy.cpp
diff --git a/cc/CCThreadProxy.cpp b/cc/CCThreadProxy.cpp
index 92550104579d2fc8e98e07cee4078f558aeb8fe9..184ec514826c436fc68e00edce7c78451a2382ca 100644
--- a/cc/CCThreadProxy.cpp
+++ b/cc/CCThreadProxy.cpp
@@ -332,6 +332,13 @@ void CCThreadProxy::onVSyncParametersChanged(double monotonicTimebase, double in
m_schedulerOnImplThread->setTimebaseAndInterval(monotonicTimebase, intervalInSeconds);
}
+void CCThreadProxy::onCanDrawStateChanged(bool canDraw)
+{
+ ASSERT(isImplThread());
+ TRACE_EVENT1("cc", "CCThreadProxy::onCanDrawStateChanged", "canDraw", canDraw);
+ m_schedulerOnImplThread->setCanDraw(canDraw);
+}
+
void CCThreadProxy::setNeedsCommitOnImplThread()
{
ASSERT(isImplThread());
@@ -522,8 +529,10 @@ void CCThreadProxy::beginFrame()
m_commitRequestSentToImplThread = false;
m_forcedCommitRequested = false;
- if (!m_layerTreeHost->initializeRendererIfNeeded())
+ if (!m_layerTreeHost->initializeRendererIfNeeded()) {
+ TRACE_EVENT0("cc", "EarlyOut_InitializeFailed");
return;
+ }
if (request->contentsTexturesWereDeleted)
m_layerTreeHost->evictAllContentTextures();
@@ -573,6 +582,7 @@ void CCThreadProxy::beginFrameCompleteOnImplThread(CCCompletionEvent* completion
ASSERT(m_schedulerOnImplThread->commitPending());
if (!m_layerTreeHostImpl) {
+ TRACE_EVENT0("cc", "EarlyOut_NoLayerTree");
completion->signal();
return;
}
@@ -610,14 +620,6 @@ bool CCThreadProxy::hasMoreResourceUpdates() const
return m_currentTextureUpdateControllerOnImplThread->hasMoreUpdates();
}
-bool CCThreadProxy::canDraw()
-{
- ASSERT(isImplThread());
- if (!m_layerTreeHostImpl)
- return false;
- return m_layerTreeHostImpl->canDraw();
-}
-
void CCThreadProxy::scheduledActionUpdateMoreResources(double monotonicTimeLimit)
{
TRACE_EVENT0("cc", "CCThreadProxy::scheduledActionUpdateMoreResources");
@@ -868,8 +870,8 @@ void CCThreadProxy::initializeRendererOnImplThread(CCCompletionEvent* completion
*initializeSucceeded = m_layerTreeHostImpl->initializeRenderer(m_contextBeforeInitializationOnImplThread.release(), textureUploader);
if (*initializeSucceeded) {
*capabilities = m_layerTreeHostImpl->rendererCapabilities();
- if (capabilities->usingSwapCompleteCallback)
- m_schedulerOnImplThread->setMaxFramesPending(2);
+ m_schedulerOnImplThread->setSwapBuffersCompleteSupported(
+ capabilities->usingSwapCompleteCallback);
}
completion->signal();
« no previous file with comments | « cc/CCThreadProxy.h ('k') | cc/LayerChromium.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698