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

Unified Diff: third_party/WebKit/Source/platform/graphics/paint/PaintChunkProperties.h

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/platform/graphics/paint/PaintChunkProperties.h
diff --git a/third_party/WebKit/Source/platform/graphics/paint/PaintChunkProperties.h b/third_party/WebKit/Source/platform/graphics/paint/PaintChunkProperties.h
index 2f095e49575a5243d506470509a6bdc295a2ad9d..e4605135e9616e5a99a6eacb3167bceea6d52377 100644
--- a/third_party/WebKit/Source/platform/graphics/paint/PaintChunkProperties.h
+++ b/third_party/WebKit/Source/platform/graphics/paint/PaintChunkProperties.h
@@ -27,7 +27,7 @@ namespace blink {
struct PaintChunkProperties {
DISALLOW_NEW_EXCEPT_PLACEMENT_NEW();
- PaintChunkProperties() : backfaceHidden(false) {}
+ PaintChunkProperties() : backfaceHidden(false), willChangeTransform(false) {}
// TODO(pdr): Refactor these to use PropertyTreeState.
RefPtr<const TransformPaintPropertyNode> transform;
@@ -35,6 +35,11 @@ struct PaintChunkProperties {
RefPtr<const EffectPaintPropertyNode> effect;
RefPtr<const ScrollPaintPropertyNode> scroll;
bool backfaceHidden;
+ bool willChangeTransform;
+
+ bool hasDirectCompositingReasons() const {
+ return backfaceHidden || willChangeTransform;
+ }
};
// Equality is based only on the pointers and is not 'deep' which would require
@@ -44,7 +49,8 @@ inline bool operator==(const PaintChunkProperties& a,
return a.transform.get() == b.transform.get() &&
a.clip.get() == b.clip.get() && a.effect.get() == b.effect.get() &&
a.scroll.get() == b.scroll.get() &&
- a.backfaceHidden == b.backfaceHidden;
+ a.backfaceHidden == b.backfaceHidden &&
+ a.willChangeTransform == b.willChangeTransform;
}
inline bool operator!=(const PaintChunkProperties& a,

Powered by Google App Engine
This is Rietveld 408576698