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

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

Issue 2059433002: Use transform paint property nodes in SVG [spv2] (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@svgTransformProps2
Patch Set: Post-blinkon rebase, add some dchecks, add some fixmes Created 4 years, 6 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
Index: third_party/WebKit/Source/core/paint/SVGRootPainter.cpp
diff --git a/third_party/WebKit/Source/core/paint/SVGRootPainter.cpp b/third_party/WebKit/Source/core/paint/SVGRootPainter.cpp
index f23a85a88a1e0b6bee91882f71d7dbb186b08b60..9436a8d31924bf9055419177eb379c4a27bfb566 100644
--- a/third_party/WebKit/Source/core/paint/SVGRootPainter.cpp
+++ b/third_party/WebKit/Source/core/paint/SVGRootPainter.cpp
@@ -14,7 +14,6 @@
#include "core/paint/TransformRecorder.h"
#include "core/svg/SVGSVGElement.h"
#include "platform/graphics/paint/ClipRecorder.h"
-#include "platform/graphics/paint/ScopedPaintChunkProperties.h"
#include "wtf/Optional.h"
namespace blink {
@@ -41,19 +40,6 @@ void SVGRootPainter::paint(const PaintInfo& paintInfo, const LayoutPoint& paintO
PaintInfo paintInfoBeforeFiltering(paintInfo);
- Optional<ScopedPaintChunkProperties> propertyScope;
- if (RuntimeEnabledFeatures::slimmingPaintV2Enabled()) {
- const auto* objectProperties = m_layoutSVGRoot.objectPaintProperties();
- // If a transform exists, we can rely on a paint layer existing to apply it.
- DCHECK(!objectProperties || !objectProperties->transform() || m_layoutSVGRoot.hasLayer());
- if (objectProperties && objectProperties->svgLocalToBorderBoxTransform()) {
- auto& paintController = paintInfoBeforeFiltering.context.getPaintController();
- PaintChunkProperties properties(paintController.currentPaintChunkProperties());
- properties.transform = objectProperties->svgLocalToBorderBoxTransform();
- propertyScope.emplace(paintController, properties);
- }
- }
-
// Apply initial viewport clip.
Optional<ClipRecorder> clipRecorder;
if (m_layoutSVGRoot.shouldApplyViewportClip()) {
@@ -72,7 +58,7 @@ void SVGRootPainter::paint(const PaintInfo& paintInfo, const LayoutPoint& paintO
paintOffsetToBorderBox.multiply(m_layoutSVGRoot.localToBorderBoxTransform());
paintInfoBeforeFiltering.updateCullRect(paintOffsetToBorderBox);
- TransformRecorder transformRecorder(paintInfoBeforeFiltering.context, m_layoutSVGRoot, paintOffsetToBorderBox);
+ SVGTransformContext transformContext(paintInfoBeforeFiltering.context, m_layoutSVGRoot, paintOffsetToBorderBox);
SVGPaintContext paintContext(m_layoutSVGRoot, paintInfoBeforeFiltering);
if (paintContext.paintInfo().phase == PaintPhaseForeground && !paintContext.applyClipMaskAndFilterIfNecessary())
« no previous file with comments | « third_party/WebKit/Source/core/paint/SVGPaintContext.h ('k') | third_party/WebKit/Source/core/paint/SVGShapePainter.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698