This forum has been archived. All content is frozen. Please use KDE Discuss instead.

Tilt mapping

Tags: None
(comma "," separated)
User avatar
Sandra
Registered Member
Posts
6
Karma
0

Tilt mapping

Sun Jan 28, 2018 8:42 pm
The other question I had was about the tilt-to-angle mapping itself. The "tilt outline" cursor maps well to my tilt. But the brush itself seems to be off... not sure if it maps 360° to 180°, or the other way around, or if there's a stray ABS in there that turns negatives to positives, or what. But tilting down seems to be 90° off from tilting up whereas 180° would be expected.
User avatar
Sandra
Registered Member
Posts
6
Karma
0

Re: Tilt mapping

Mon Feb 05, 2018 8:40 am
Yep!

I tried changing
Code: Select all
        else if (m_settings->moirepattern) {
            m_hatchingBrush->hatch(m_hatchedDab, x, y, sw, sh, spinAngle((m_settings->crosshatchingsensorvalue) * 180), painter()->paintColor(), additionalScale);
            donotbasehatch = true;
        }


to
Code: Select all
        else if (m_settings->moirepattern) {
            m_hatchingBrush->hatch(m_hatchedDab, x, y, sw, sh, spinAngle((m_settings->crosshatchingsensorvalue) * 360), painter()->paintColor(), additionalScale);
            donotbasehatch = true;
        }

in kis_hatching_paintop.cpp and recompiled it and tested it and that fixed it! I'll make a patch once I've fixed the other thing I really wanted to fix (adding an angle parameter).

(Devs: If I forget to do that or die or something then feel free to make the change based on this post. We don't really need a patch to just change two characters♥)

Edit: This also makes the "Drawing angle", work better (but don't combine it with tilt direction, use one or the other). It was working weirdly before.


Bookmarks



Who is online

Registered users: Bing [Bot], Google [Bot], kde-naveen, Sogou [Bot], Yahoo [Bot]