Diffusion Krita 2e8294becc66

Fix rendering of vector masks applied to group shapes

Authored by dkazakov on Nov 29 2019, 5:31 PM.

Description

Fix rendering of vector masks applied to group shapes

The patch does multiple things:

  1. Refactors KoShapeManager::paint() to use KisForest implementation to render shapes hierarchy. It is needed because we need to be able only a part of the shapes, and their parents might have filtering or masks. Theoretically, it is possible to implement this algorithm without KisForest, but it this case populateRenderSubtree(), buildRenderTree() and renderShapes() will be merged into a single function (or some counter-intuitive templated strategy), which would make the code hard to debug and maintain.
  1. KoViewConverter is gone! Gone! You hear it?! It is gone!!! No more KoViewConverter in any rendering! :) Well, it is still used in the tools, but we can live with it for now. The main point, there is no ugly hacks in KoShape::absoluteTransformation() to correct shape's offset to let view scaling transform be applied *after* the shape. Now view tranform in applied *before* the shapes, right in KisShapeLayerCanvas (or the like).

The code touches a lot of code, so some testing is needed.

Things that were deprecated:

  • SVG-filtering rendering code was removed. It used an ugly hack to let it work on groups. It couldn't be kept after refactoring. When we implement it correctly, it should be just placed into renderShapes().
  • some features of ODF text and raster-based vector patterns might have become broken. But we have no way to test that :(

BUG:392242

Details

Committed
dkazakovNov 29 2019, 5:31 PM
Parents
R37:9212bea1a2ca: Fix loading SVG files with symbols
Branches
Unknown
Tags
Unknown