Rotation related to canvas
Lukast dev
lukast.dev at gmail.com
Thu Feb 23 11:19:20 UTC 2012
Hello all,
Dmitry, would you please take a look at my patch for bug
https://bugs.kde.org/show_bug.cgi?id=292726
There is one problem in KisToolFreehand::getOutlinePath where I need
to distict between
two states:
a) In hover mode the rotation of the canvas has to be included in the
computation of the brush outline.
In that moment the rotation of the brush engine is not known as we
don't know the state of the
rotation sensors etc.
b) In paint mode the rotation of the canvas is included in the brush
engine rotation and thus we don't
include it again when computing the outline in freehand tool. Problem
is that we need to call paintAt at least once so
that the sensors set the currentRotation of the paintop correctly. So
far I added boolean flag to KisPaintOp::setCurrentRotation
but I wonder we if can do it nicely. I tried to add flag after
doStroke() in freehand tool, but it is threaded and the paintAt call
is scheduled and thus at the beginning of the stroke the outline is wrong.
My question, Dmitry, is if you can see in freehand tool if the paintop
paintAt was executed at least once somehow?
If you have any concerns about the patch, let me know.
Cheers
Lukas
-------------- next part --------------
A non-text attachment was scrubbed...
Name: rotation_to_canvas.patch
Type: text/x-patch
Size: 7103 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kimageshop/attachments/20120223/0a0677b3/attachment.patch>
More information about the kimageshop
mailing list