Bug 343187

Summary: Shaped gradient has artifacts when the selection has holes inside
Product: [Applications] krita Reporter: Dmitry Kazakov <dimula73>
Component: ToolsAssignee: Dmitry Kazakov <dimula73>
Status: RESOLVED FIXED    
Severity: normal CC: halla, rafal.trashbin
Priority: NOR    
Version: git master (please specify the git hash!)   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:
Attachments: Illustration of the bug

Description Dmitry Kazakov 2015-01-23 11:05:36 UTC
Created attachment 90600 [details]
Illustration of the bug

See attached image
Comment 1 Dmitry Kazakov 2015-02-01 12:26:12 UTC
Git commit 92ed1f413e3b70ec250061e81b46e444ca9d30b9 by Dmitry Kazakov.
Committed on 01/02/2015 at 11:24.
Pushed by dkazakov into branch 'calligra/2.9'.

Fix shaped gradient for selections with holes

Now it can handle selections defined by QPainterPath objects.

There is a small problem though. If you have three selections
included into each other twice, then the smallest selection may
have wrong value. It should be fixed in KritaUtils::splitDisjointPaths()
but it is really minor bug.

M  +10   -9    krita/image/kis_gradient_painter.cc
M  +196  -37   krita/image/kis_polygonal_gradient_shape_strategy.cpp
M  +7    -2    krita/image/kis_polygonal_gradient_shape_strategy.h
M  +49   -0    krita/image/krita_utils.cpp
M  +12   -0    krita/image/krita_utils.h
M  +142  -3    krita/image/tests/kis_gradient_painter_test.cpp
M  +5    -0    krita/image/tests/kis_gradient_painter_test.h

http://commits.kde.org/calligra/92ed1f413e3b70ec250061e81b46e444ca9d30b9
Comment 2 Halla Rempt 2017-11-08 11:17:58 UTC
*** Bug 377765 has been marked as a duplicate of this bug. ***