Bug 471896

Summary: Fill tool on tagged layers doesn't work as expected with filter layers
Product: [Applications] krita Reporter: Dmitry Kazakov <dimula73>
Component: ToolsAssignee: Krita Bugs <krita-bugs-null>
Status: RESOLVED FIXED    
Severity: normal    
Priority: NOR    
Version: git master (please specify the git hash!)   
Target Milestone: ---   
Platform: Other   
OS: Other   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description Dmitry Kazakov 2023-07-03 09:01:16 UTC
STEPS TO REPRODUCE
1. Create a document with the following structure:
   L4. Empty layer, [no color label] 
   L3. Adjustment Layer (Color Adjustment curves), [RED color label]
   L2. Paint layer with a circle painted on it, [no color label] 
   L1. Background layer filled with white, [RED color label]
2. Activate the empty layer L4
3. Activate Fill Tool, Select "Fill by RED color label"
4. Try to fill the circle with the fill tool

OBSERVED RESULT
The entire canvas is filled

EXPECTED RESULT
The tool should behave exactly as in "Fill by Merged Image" mode

Here is a screen recording of the problem:
https://disk.yandex.ru/i/nyHgTVadKHV9-A

Notes:

It seems like the Adjustment layer should be rasterized before being copied into a separate image for the reference.
Comment 1 Bug Janitor Service 2023-07-28 10:34:03 UTC
A possibly relevant merge request was started @ https://invent.kde.org/graphics/krita/-/merge_requests/1872
Comment 2 Deif Lou 2023-08-01 05:13:56 UTC
Git commit 943278915682af369ef76cdc24c83f4f98da4530 by Deif Lou.
Committed on 01/08/2023 at 06:55.
Pushed by deiflou into branch 'master'.

Fix issues generating reference image in KisMergeLabeledLayersCommand
Related: bug 472700

M  +113  -35   libs/image/commands_new/KisMergeLabeledLayersCommand.cpp
M  +4    -5    libs/image/commands_new/KisMergeLabeledLayersCommand.h

https://invent.kde.org/graphics/krita/-/commit/943278915682af369ef76cdc24c83f4f98da4530
Comment 3 Dmitry Kazakov 2024-02-28 18:09:59 UTC
Git commit 44f0d93ef6fa3c8e46d23af53346c4854b63ac45 by Dmitry Kazakov, on behalf of Deif Lou.
Committed on 28/02/2024 at 12:34.
Pushed by dkazakov into branch 'kazakov/for-5.2'.

Fix issues generating reference image in KisMergeLabeledLayersCommand
Related: bug 472700

M  +113  -35   libs/image/commands_new/KisMergeLabeledLayersCommand.cpp
M  +4    -5    libs/image/commands_new/KisMergeLabeledLayersCommand.h

https://invent.kde.org/graphics/krita/-/commit/44f0d93ef6fa3c8e46d23af53346c4854b63ac45