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

Unified Diff: cc/trees/property_tree.cc

Issue 2814273003: cc: Make DamageTracker use the effect tree and layer list (Closed)
Patch Set: Rebase Created 3 years, 8 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/property_tree.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/trees/property_tree.cc
diff --git a/cc/trees/property_tree.cc b/cc/trees/property_tree.cc
index 4d1ca75e38725d81b8a92cbc6e33368921b26a74..280ecd000bffb759bce8db68e84e65719c3c146c 100644
--- a/cc/trees/property_tree.cc
+++ b/cc/trees/property_tree.cc
@@ -1012,6 +1012,20 @@ int EffectTree::ClosestAncestorWithCopyRequest(int id) const {
return EffectTree::kInvalidNodeId;
}
+int EffectTree::LowestCommonAncestorWithRenderSurface(int id_1,
+ int id_2) const {
+ DCHECK(GetRenderSurface(id_1));
+ DCHECK(GetRenderSurface(id_2));
+ while (id_1 != id_2) {
+ if (id_1 < id_2)
+ id_2 = Node(id_2)->target_id;
+ else
+ id_1 = Node(id_1)->target_id;
+ }
+
+ return id_1;
+}
+
void EffectTree::AddMaskLayerId(int id) {
mask_layer_ids_.push_back(id);
}
« no previous file with comments | « cc/trees/property_tree.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698