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

Unified Diff: third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.cpp

Issue 2565073002: Implement the algorithm to test merging and overlap in PaintArtifactCompositor. (Closed)
Patch Set: none Created 4 years 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: third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.cpp
diff --git a/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.cpp b/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.cpp
index a0a17d3962ef13e7d138575fc7b25be600a0f5ca..c62a1e9af3837e45b579460999d6eb70e4bb54be 100644
--- a/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.cpp
+++ b/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.cpp
@@ -9,6 +9,7 @@
#include "core/frame/Settings.h"
#include "core/layout/LayoutInline.h"
#include "core/layout/LayoutView.h"
+#include "core/layout/compositing/CompositingReasonFinder.h"
#include "core/layout/svg/LayoutSVGRoot.h"
#include "core/paint/FindPropertiesNeedingUpdate.h"
#include "core/paint/ObjectPaintProperties.h"
@@ -122,6 +123,9 @@ void PaintPropertyTreeBuilder::updateProperties(
return;
}
+ m_compositingReasonFinder.reset(
+ new CompositingReasonFinder(*frameView.layoutView()));
+
#if DCHECK_IS_ON()
FindFrameViewPropertiesNeedingUpdateScope checkScope(&frameView, context);
#endif
@@ -338,7 +342,10 @@ void PaintPropertyTreeBuilder::updateTransform(
context.forceSubtreeUpdate |= properties.updateTransform(
context.current.transform, matrix,
transformOrigin(toLayoutBox(object)),
- context.current.shouldFlattenInheritedTransform, renderingContextID);
+ context.current.shouldFlattenInheritedTransform, renderingContextID,
+ m_compositingReasonFinder->directReasons(
+ toLayoutBoxModelObject(&object)->layer()) &
+ CompositingReason3DTransform);
} else {
if (auto* properties = object.getMutableForPainting().paintProperties())
context.forceSubtreeUpdate |= properties->clearTransform();

Powered by Google App Engine
This is Rietveld 408576698