Bug 457957

Summary: Group transformations snap back to original location in preview when containing a filter layer.
Product: [Applications] krita Reporter: Ralek Kolemios <info>
Component: OpenGL CanvasAssignee: Krita Bugs <krita-bugs-null>
Status: RESOLVED FIXED    
Severity: normal CC: dimula73
Priority: NOR    
Version: git master (please specify the git hash!)   
Target Milestone: ---   
Platform: Appimage   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:
Attachments: Snap example

Description Ralek Kolemios 2022-08-16 12:49:00 UTC
Created attachment 151354 [details]
Snap example

Under specific circumstances that I haven't been able to reproduce from scratch, transforming a group that contains a filter layer will snap back to its original position in the canvas preview once the transformation completes. This only happens on the 'accurate with instant preview' setting.

I've attached a test file that has this problem, simply transform 'group 31' with the transformation tool and press enter.

Probably related, the 'move' tool also doesn't work on this group.

Both tools do their jobs properly behind the scenes, but the preview does not update until the layer is hidden and re-shown.

Version: 5.2.0-prealpha (git 78cca8f)
Comment 1 Ralek Kolemios 2022-12-17 23:58:00 UTC
Similarly, I have also recently noticed that undoing a transformation like this does not 'work'. It works behind the scenes like the original transformation, but it does not update the canvas.
5.2.0-prealpha (git 220e4cd)
Comment 2 Ralek Kolemios 2024-04-16 00:43:27 UTC
Can still confirm this in 5.3 prealpha, though it manifests slightly differently.
The original transformation of group 31 finishes correctly now, but undoing the operation afterwards doesn't update the canvas. (The undo does still work behind the scenes, like in the original report)
Move tool is still non-functional on Group 31.
Comment 3 Dmitry Kazakov 2024-09-11 10:32:15 UTC
The problem happens because of the pass-through mode in the transformed group
Comment 4 Dmitry Kazakov 2024-09-16 15:38:21 UTC
Git commit c2c12c46bf53e3a81d4ce200f2ec0a86bf586d47 by Dmitry Kazakov.
Committed on 16/09/2024 at 15:36.
Pushed by dkazakov into branch 'master'.

Fix Move and Transform tool to work with Pass-Through groups

Pass-through groups are not present in the layers stack, so we changing
them (or theirs children), we should update their parent instead.

M  +35   -3    libs/image/kis_image.cc

https://invent.kde.org/graphics/krita/-/commit/c2c12c46bf53e3a81d4ce200f2ec0a86bf586d47
Comment 5 Dmitry Kazakov 2024-09-16 15:39:14 UTC
Git commit 4edaf55f701b9d989edb3d54a7761e2ea8d37724 by Dmitry Kazakov.
Committed on 16/09/2024 at 15:38.
Pushed by dkazakov into branch 'krita/5.2'.

Fix Move and Transform tool to work with Pass-Through groups

Pass-through groups are not present in the layers stack, so we changing
them (or theirs children), we should update their parent instead.

M  +35   -3    libs/image/kis_image.cc

https://invent.kde.org/graphics/krita/-/commit/4edaf55f701b9d989edb3d54a7761e2ea8d37724