Beep6581 / RawTherapee

A powerful cross-platform raw photo processing program
https://rawtherapee.com
GNU General Public License v3.0
2.94k stars 328 forks source link

Locallab slider in the wrong scale #6813

Closed Hombre57 closed 1 year ago

Hombre57 commented 1 year ago

I played with the local editing tools and found a somewhat weird behavior with the Common Color Mask - 12 and the Add/substract Luminance mask slider. The rendering is swapping multiple times. I wonder if it is used at the correct scale : it's -100/+100 on the slider, shouldn't it be -1./+1. in iplocallab ?

For example, I have a more understandable behavior with this patch applied :

diff --git a/rtengine/iplocallab.cc b/rtengine/iplocallab.cc
index 6db6b76..38e2900 100644
--- a/rtengine/iplocallab.cc
+++ b/rtengine/iplocallab.cc
@@ -5342,6 +5342,8 @@

 static void blendmask(const local_params& lp, int xstart, int ystart, int cx, int cy, int bfw, int bfh, LabImage* bufexporig, LabImage* original, LabImage* bufmaskor, LabImage* originalmas, float bl, float blab, int inv)
 {
+    bl /= 100.f;
+
 #ifdef _OPENMP
     #pragma omp parallel for schedule(dynamic,16)
 #endif

@Desmis Could you have a look ? And see if other -100/+100 sliders are concerned ? @Beep6581 I'm adding this to 5.10, since it should be one liners and with a huge impact on usability, if you don't mind.

Desmis commented 1 year ago

@Hombre57 I think you are true, the slider is too strong :) But with bl/=100.f, in this case, the action of blend is too weak.

I think bl /= 10.f; is a good compromise.

Can you make this change, because after a quick check this seems to me the only case

Thank you

Jacques

Desmis commented 1 year ago

@Hombre57 I will push this change

jacques

Desmis commented 1 year ago

@Hombre57 The blendmask function is used in "common color mask" but also in all standard masks.

I distributed the action with 0.01 as the global coefficient for "common color mask" and 0.1 for the other masks

Thank you again.

I am not at home, but in mountains... I try to rest, the disease regresses, but the consequences on sleep and digestion are still very important

Jacques