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

Unified Diff: cc/trees/layer_tree_host.cc

Issue 25912003: cc: Stop using magic numbers to detect if we can use partial updates. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 2 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/trees/layer_tree_host.h ('k') | cc/trees/layer_tree_host_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/trees/layer_tree_host.cc
diff --git a/cc/trees/layer_tree_host.cc b/cc/trees/layer_tree_host.cc
index e3a1b32924839b697d18d135ad0b816ef3711d81..34f4d2f65d29a0d4d956cef669870e988b1d6240 100644
--- a/cc/trees/layer_tree_host.cc
+++ b/cc/trees/layer_tree_host.cc
@@ -1118,6 +1118,12 @@ void LayerTreeHost::RateLimit() {
proxy_->ForceSerializeOnSwapBuffers();
}
+bool LayerTreeHost::AlwaysUsePartialTextureUpdates() {
+ if (!proxy_->GetRendererCapabilities().allow_partial_texture_updates)
+ return false;
+ return !proxy_->HasImplThread();
+}
+
bool LayerTreeHost::RequestPartialTextureUpdate() {
if (partial_texture_update_requests_ >= settings_.max_partial_texture_updates)
return false;
« no previous file with comments | « cc/trees/layer_tree_host.h ('k') | cc/trees/layer_tree_host_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698