Bug 292726 - Brush rotation should be absolute, not relative to canvas rotation
Summary: Brush rotation should be absolute, not relative to canvas rotation
Status: RESOLVED FIXED
Alias: None
Product: krita
Classification: Applications
Component: Usability (show other bugs)
Version: git master (please specify the git hash!)
Platform: Unlisted Binaries Linux
: NOR major
Target Milestone: ---
Assignee: Dmitry Kazakov
URL:
Keywords:
: 411078 (view as bug list)
Depends on:
Blocks:
 
Reported: 2012-01-28 21:44 UTC by animtim
Modified: 2019-08-22 10:07 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description animtim 2012-01-28 21:44:15 UTC
Version:           svn trunk (using KDE 4.8.0) 
OS:                Linux

Current brush angle follows the canvas when you rotate it. This is a bad behavior because the same phisycal brush stroke should have the same output on screen no matter how the canvas is rotated, which is so not the case now.

Reproducible: Always

Steps to Reproduce:
simple way to observe it:
take a flat brush, without any sensor activated on rotation (actually this happens also with any sensor activated on rotation, except "Drawing angle" which looks to be good.).
Draw a line, let's say, from left to right of the screen;
Rotate the canvas 90°, and draw another line from left to right of the screen;

Actual Results:  
The second line/stroke is different from the first one (brush follow the canvas 90° rotation)


Expected Results:  
Both strokes should look the same (brush angle shouldn't rotate with canvas)

This is particulary annoying when using a brush with rotation linked to "Ascension", because then again you would expect the brush angle to be relative only to stylus angle, independant from canvas position/rotation (like in real life when you move or rotate the paper)
Comment 1 Halla Rempt 2012-01-29 09:20:16 UTC
Yes, I see... I think it's always been this way, though!
Comment 2 animtim 2012-01-29 11:31:39 UTC
Yes indeed, it's always been like that in Krita, just I didn't notice it
until now.

(I guess I didn't notice it in 2.3 as we didn't have ascension/declination
sensors yet, and I used mostly round brushes)
Comment 3 LukasT 2012-05-26 13:15:03 UTC
Git commit 5c91a3e0c9597de7e8dd320c60f3f56881d4b5ce by Lukáš Tvrdý.
Committed on 26/05/2012 at 15:06.
Pushed by lukast into branch 'master'.

Make brush rotation absolute to canvas rotation

o pass the canvas rotation to rotation sensor
  and remap the rotation accoring current status
  of the canvas

o also rendering of the brush outline has to respect
  canvas rotation

M  +11   -0    krita/image/brushengine/kis_paintop_settings.cpp
M  +3    -0    krita/image/brushengine/kis_paintop_settings.h
M  +2    -2    krita/plugins/paintops/defaultpaintops/brush/kis_brushop.cpp
M  +10   -3    krita/plugins/paintops/libpaintop/kis_pressure_rotation_option.cpp
M  +3    -0    krita/plugins/paintops/libpaintop/kis_pressure_rotation_option.h
M  +5    -0    krita/ui/canvas/kis_canvas2.cpp
M  +2    -0    krita/ui/canvas/kis_canvas2.h
M  +6    -0    krita/ui/tool/kis_tool_freehand.cc

http://commits.kde.org/calligra/5c91a3e0c9597de7e8dd320c60f3f56881d4b5ce
Comment 4 LukasT 2012-05-26 14:54:27 UTC
Fix confirmed by Animtim
> (04:24:15 PM) Animtim: LukasT: ok you can close the bug 292726, thank 
> youuu :)
Comment 5 Przemysław Gołąb 2019-08-19 20:04:03 UTC
This bug is back.
Comment 6 Halla Rempt 2019-08-20 06:47:41 UTC
*** Bug 411078 has been marked as a duplicate of this bug. ***
Comment 7 Halla Rempt 2019-08-20 07:38:20 UTC
Maybe caused by 

Git commit c74ddaf2991833c7c587dec47f53456ec36304e2 by Boudewijn Rempt, on behalf of Dmitry Kazakov.
Committed on 02/08/2019 at 08:26.
Pushed by rempt into branch 'krita/4.2'.

Fix Tangent-Normal brush on rotated/mirrored canvas

(and also in multihand brush)

Now the canvas rotation/mirroing code is fully ported to the new
API, by passing via KisPaintInformation instead of paintop settings'
temporary properties.

BUG:404408

?
Comment 8 Halla Rempt 2019-08-20 07:57:47 UTC
Dmitry confirms this suspicion.
Comment 9 Dmitry Kazakov 2019-08-22 10:04:06 UTC
Git commit d8f90d4a8968e50e709833de8543776860dcbbcb by Dmitry Kazakov.
Committed on 22/08/2019 at 10:03.
Pushed by dkazakov into branch 'master'.

[REGRESSION] Fix absolute brush rotation on rotated canvas

The regression was caused by c74ddaf2991833c7c587dec47f53456ec36304e2

M  +1    -1    plugins/paintops/libpaintop/kis_pressure_rotation_option.cpp

https://invent.kde.org/kde/krita/commit/d8f90d4a8968e50e709833de8543776860dcbbcb
Comment 10 Dmitry Kazakov 2019-08-22 10:07:28 UTC
Git commit 1a9077c3df45438350b1912009ea0ddaf0fb0fee by Dmitry Kazakov.
Committed on 22/08/2019 at 10:07.
Pushed by dkazakov into branch 'krita/4.2'.

[REGRESSION] Fix absolute brush rotation on rotated canvas

The regression was caused by c74ddaf2991833c7c587dec47f53456ec36304e2

M  +1    -1    plugins/paintops/libpaintop/kis_pressure_rotation_option.cpp

https://invent.kde.org/kde/krita/commit/1a9077c3df45438350b1912009ea0ddaf0fb0fee