Bug 387507 - Fuzzy Dab/Stroke not scaling with "Strength" for HSV options in pixel brush.
Summary: Fuzzy Dab/Stroke not scaling with "Strength" for HSV options in pixel brush.
Status: RESOLVED FIXED
Alias: None
Product: krita
Classification: Applications
Component: Brush engines (show other bugs)
Version: 3.3.2
Platform: Microsoft Windows Microsoft Windows
: NOR normal
Target Milestone: ---
Assignee: Krita Bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-12-01 16:45 UTC by brummerke90
Modified: 2018-02-09 12:34 UTC (History)
2 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 brummerke90 2017-12-01 16:45:53 UTC
Fuzzy stroke is useful for adding slight value and hue variation to your strokes, but it's really hard to make it subtle (which is how it's supposed to be used most of the time), because the "strength" slider doesn't apply to it; it produces the same amount of variation regardless of where the slider is.
So the effect can only be scaled by changing the curve, but even using that, it cannot be fine-tuned to be very subtle, since the resolution of the UI doesn't allow for it; https://i.imgur.com/aw3TJPi.png
I think the strength slider should apply here, since it's not used for anything else.
Comment 1 wolthera 2017-12-01 18:38:29 UTC
Confirmed. It seems that "computeRotationLikeValue" doesn't take into account thestrength slider, and I can't quite figure out if the only other place this function is used(KisPressureRotationOption) also should take into account strength or not.

Anyway, I am neck deep in refactorings elsewhere, so I'll post my diff that fixes the issue here:

diff --git a/plugins/paintops/libpaintop/kis_pressure_hsv_option.cpp b/plugins/paintops/libpaintop/kis_pressure_hsv_option.cpp
index cf6f630..a0c8217 100644
--- a/plugins/paintops/libpaintop/kis_pressure_hsv_option.cpp
+++ b/plugins/paintops/libpaintop/kis_pressure_hsv_option.cpp
@@ -132,8 +132,9 @@ void KisPressureHSVOption::apply(KoColorTransformation* transfo, const KisPaintI
         d->paramId = transfo->parameterId(d->parameterName);
     }
 
-    qreal value = computeRotationLikeValue(info, 0, false);
-    transfo->setParameter(d->paramId, value);
+    qreal v = computeRotationLikeValue(info, 0, false);
+    v = (v) * (this->value());//multiply by strength slider.
+    transfo->setParameter(d->paramId, v);
     transfo->setParameter(3, 0); //sets the type to HSV.
     transfo->setParameter(4, false); //sets the colorize to false.
 }
Comment 2 Halla Rempt 2018-02-09 12:34:52 UTC
Git commit e66421584ffa0c1c18d4688f3072ae14f7e83da2 by Boudewijn Rempt.
Committed on 09/02/2018 at 12:34.
Pushed by rempt into branch 'master'.

Scale Fuzzy dab/stroke with strength for hsv options

Patch by Wolthera, taken from bug 387507.

M  +3    -2    plugins/paintops/libpaintop/kis_pressure_hsv_option.cpp

https://commits.kde.org/krita/e66421584ffa0c1c18d4688f3072ae14f7e83da2