diff --git a/rtdata/languages/default b/rtdata/languages/default
index f3067f8e6..60d2d54ea 100644
--- a/rtdata/languages/default
+++ b/rtdata/languages/default
@@ -1157,8 +1157,11 @@ HISTORY_MSG_916;Local - Residual wavelet shadows
HISTORY_MSG_917;Local - Residual wavelet shadows threshold
HISTORY_MSG_918;Local - Residual wavelet highlights
HISTORY_MSG_919;Local - Residual wavelet highlights threshold
-HISTORY_MSG_920;Local - Tool complexity mode
-HISTORY_MSG_921;Local - Tool complexity mode
+HISTORY_MSG_920;Local - Wavelet sigma LC
+HISTORY_MSG_921;Local - Wavelet Graduated sigma LC2
+HISTORY_MSG_922;Local - changes In Black and White
+HISTORY_MSG_923;Local - Tool complexity mode
+HISTORY_MSG_924;Local - Tool complexity mode
HISTORY_MSG_CAT02PRESET;Cat02 automatic preset
HISTORY_MSG_CLAMPOOG;Clip out-of-gamut colors
HISTORY_MSG_COLORTONING_LABGRID_VALUE;CT - Color correction
@@ -1335,6 +1338,7 @@ IPTCPANEL_TITLE;Title
IPTCPANEL_TITLEHINT;Enter a short verbal and human readable name for the image, this may be the file name.
IPTCPANEL_TRANSREFERENCE;Job ID
IPTCPANEL_TRANSREFERENCEHINT;Enter a number or identifier needed for workflow control or tracking.
+LOCAL_HELP;Help Local Adjustments
MAIN_BUTTON_FULLSCREEN;Fullscreen
MAIN_BUTTON_ICCPROFCREATOR;ICC Profile Creator
MAIN_BUTTON_NAVNEXT_TOOLTIP;Navigate to the next image relative to image opened in the Editor.\nShortcut: Shift-F4\n\nTo navigate to the next image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F4
@@ -1549,7 +1553,7 @@ PREFERENCES_CLUTSCACHE;HaldCLUT Cache
PREFERENCES_CLUTSCACHE_LABEL;Maximum number of cached CLUTs
PREFERENCES_CLUTSDIR;HaldCLUT directory
PREFERENCES_CMMBPC;Black point compensation
-PREFERENCES_COMPLEXITYLOC;Complexity Local Adjustements
+PREFERENCES_COMPLEXITYLOC;Default complexity for Local Adjustements
PREFERENCES_COMPLEXITY_EXP;Expert
PREFERENCES_COMPLEXITY_NORM;Normal
PREFERENCES_CROP;Crop Editing
@@ -2299,6 +2303,8 @@ TP_LOCALLAB_BLMED;Median
TP_LOCALLAB_BLMETHOD_TOOLTIP;Normal - direct blur and noise with all settings.\nInverse - Inverse blur and noise without scope and without enhanced algorithm.\nSymmetric - inverse blur and noise with all settings. Be careful some results may be curious
TP_LOCALLAB_BLNORM;Normal
TP_LOCALLAB_BLSYM;Symmetric
+TP_LOCALLAB_BLWH;All changes forced in Black and White
+TP_LOCALLAB_BLWH_TOOLTIP;Force color change composante "a" and "b" to zero.
TP_LOCALLAB_SPOTNAME;New Spot
TP_LOCALLAB_BLUFR;Smooth - Blur - Grain - Denoise
TP_LOCALLAB_BLUMETHOD_TOOLTIP;To blur the background and isolate the foreground:\n*Blur the background by a RT-spot fully covering the image (high values for scope and transition) - normal or inverse.\n*Isolate the foreground by one or more excluding RT-spot with the tools you want (increse scope), you can use a mask to enhance and amplify the effects.\n\nThis module can be used in additional noise reduction,including "median" and "Guided filter"
@@ -2323,6 +2329,7 @@ TP_LOCALLAB_CHROMACBDL;Chroma
TP_LOCALLAB_CHROMACB_TOOLTIP;Acts as an amplifier-reducer action compare to sliders of luminance.\nUnder 100 reduce, above 100 amplifie
TP_LOCALLAB_CHROMALEV;Chroma levels
TP_LOCALLAB_CHROMABLU;Chroma levels
+TP_LOCALLAB_CHROMABLU_TOOLTIP;Acts as an amplifier-reducer action compare to settings of luma.\nUnder 1 reduce, above 1 amplifie
TP_LOCALLAB_CHROMASKCOL;Chroma mask
TP_LOCALLAB_CHROMASK_TOOLTIP;You can use this slider to desaturated background (inverse mask - curve near 0).\nAlso to attenuate or enhance the action of a mask on the chroma
TP_LOCALLAB_CHRRT;Chroma
@@ -2331,7 +2338,7 @@ TP_LOCALLAB_CLARICRES;Merge Chroma
TP_LOCALLAB_CLARIFRA;Clarity & Sharp mask - Blend & Soft images
TP_LOCALLAB_CLARILRES;Merge Luma
TP_LOCALLAB_CLARISOFT;Soft radius
-TP_LOCALLAB_CLARISOFT_TOOLTIP;Enabled for Clarity & Sharp mask.\nContrast by level.\nLevel Dynamic Range Compression.\nDirectional contrast.\nGraduated filter local contrast
+TP_LOCALLAB_CLARISOFT_TOOLTIP;Enabled for Clarity and Sharp mask if Merge Luma different from zero.\n\nEnabled for all wavelets pyramid modules.\nDisabled if Soft radius = 0
TP_LOCALLAB_CLARITYML;Clarity
TP_LOCALLAB_CLARI_TOOLTIP;Under or equal level wavelet 4, 'Sharp mask' is enabled.\nAbove level wavelet 5 'Clarity' is enabled.\nUsefull if you use 'Level dynamic Range Compression'
TP_LOCALLAB_CLIPTM;Clip Restored datas (gain)
diff --git a/rtengine/iplocallab.cc b/rtengine/iplocallab.cc
index 5aeedcee5..9eb147fcd 100644
--- a/rtengine/iplocallab.cc
+++ b/rtengine/iplocallab.cc
@@ -450,10 +450,13 @@ struct local_params {
float sigmadr;
float sigmabl;
float sigmaed;
+ float sigmalc;
+ float sigmalc2;
float residsha;
float residshathr;
float residhi;
float residhithr;
+ bool blwh;
};
@@ -1245,10 +1248,13 @@ static void calcLocalParams(int sp, int oW, int oH, const LocallabParams& locall
lp.sigmadr = locallab.spots.at(sp).sigmadr;
lp.sigmabl = locallab.spots.at(sp).sigmabl;
lp.sigmaed = locallab.spots.at(sp).sigmaed;
+ lp.sigmalc = locallab.spots.at(sp).sigmalc;
+ lp.sigmalc2 = locallab.spots.at(sp).sigmalc2;
lp.residsha = locallab.spots.at(sp).residsha;
lp.residshathr = locallab.spots.at(sp).residshathr;
lp.residhi = locallab.spots.at(sp).residhi;
lp.residhithr = locallab.spots.at(sp).residhithr;
+ lp.blwh = locallab.spots.at(sp).blwh;
}
@@ -6463,7 +6469,6 @@ void ImProcFunctions::transit_shapedetect2(int call, int senstype, const LabImag
int bfwr = bfw;
bool reduH = false;
bool reduW = false;
-
if (lp.blurcolmask >= 0.25f && lp.fftColorMask && call == 2) {
optfft(N_fftwsize, bfh, bfw, bfhr, bfwr, reduH, reduW, lp, original->H, original->W, xstart, ystart, xend, yend, cx, cy);
}
@@ -6735,6 +6740,10 @@ void ImProcFunctions::transit_shapedetect2(int call, int senstype, const LabImag
cla = bufexpfin->a[y][x] - original->a[y + ystart][x + xstart];
clb = bufexpfin->b[y][x] - original->b[y + ystart][x + xstart];
}
+ if(lp.blwh) {
+ cla = 0.f;
+ clb = 0.f;
+ }
// const float previewint = settings->previewselection;
@@ -7810,7 +7819,7 @@ void ImProcFunctions::wavcontrast4(struct local_params& lp, float ** tmp, float
}
}
}
-
+//printf("lp.sigmalc2 = %f\n", lp.sigmalc2);
float mean[10];
float meanN[10];
float sigma[10];
@@ -7839,15 +7848,21 @@ void ImProcFunctions::wavcontrast4(struct local_params& lp, float ** tmp, float
int W_L = wdspot->level_W(level);
int H_L = wdspot->level_H(level);
float **wav_L = wdspot->level_coeffs(level);
+ float effect = lp.sigmalc2;
+ float offs = 1.f;
+ float mea[10];
+ float beta = 1.f;
+ calceffect(level, mean, sigma, mea, effect, offs);
+
if (MaxP[level] > 0.f && mean[level] != 0.f && sigma[level] != 0.f) {
float insigma = 0.666f; //SD
float logmax = log(MaxP[level]); //log Max
- float rapX = (mean[level] + sigma[level]) / MaxP[level]; //rapport between sD / max
+ float rapX = (mean[level] + lp.sigmalc2 * sigma[level]) / MaxP[level]; //rapport between sD / max
float inx = log(insigma);
float iny = log(rapX);
float rap = inx / iny; //koef
- float asig = 0.166f / sigma[level];
+ float asig = 0.166f / (sigma[level] * lp.sigmalc2);
float bsig = 0.5f - asig * mean[level];
float amean = 0.5f / mean[level];
@@ -7857,11 +7872,36 @@ void ImProcFunctions::wavcontrast4(struct local_params& lp, float ** tmp, float
for (int y = 0; y < H_L; y++) {
for (int x = 0; x < W_L; x++) {
+ float WavCL = std::fabs(wav_L[dir][y * W_L + x]);
+
+ if (WavCL < mea[0]) {
+ beta = 0.05f;
+ } else if (WavCL < mea[1]) {
+ beta = 0.2f;
+ } else if (WavCL < mea[2]) {
+ beta = 0.7f;
+ } else if (WavCL < mea[3]) {
+ beta = 1.f; //standard
+ } else if (WavCL < mea[4]) {
+ beta = 1.f;
+ } else if (WavCL < mea[5]) {
+ beta = 0.8f; //+sigma
+ } else if (WavCL < mea[6]) {
+ beta = 0.6f;
+ } else if (WavCL < mea[7]) {
+ beta = 0.5f;
+ } else if (WavCL < mea[8]) {
+ beta = 0.4f; // + 2 sigma
+ } else if (WavCL < mea[9]) {
+ beta = 0.3f;
+ } else {
+ beta = 0.1f;
+ }
float absciss;
float &val = wav_L[dir][y * W_L + x];
- if (fabsf(val) >= (mean[level] + sigma[level])) { //for max
+ if (fabsf(val) >= (mean[level] + lp.sigmalc2 * sigma[level])) { //for max
float valcour = xlogf(fabsf(val));
float valc = valcour - logmax;
float vald = valc * rap;
@@ -7890,20 +7930,17 @@ void ImProcFunctions::wavcontrast4(struct local_params& lp, float ** tmp, float
}
}
- float kc = 0.5f * klev * factorwav[y][x] * absciss;
+ float kc = 0.8f * klev * factorwav[y][x] * absciss;
float reduceeffect = kc <= 0.f ? 1.f : 1.5f;
float kinterm = 1.f + reduceeffect * kc;
kinterm = kinterm <= 0.f ? 0.01f : kinterm;
-
- val *= kinterm;
+ val *= (1.f + (kinterm - 1.f) * beta);
}
}
}
}
}
-
-
}
//declare a and b if need
@@ -8557,11 +8594,11 @@ void ImProcFunctions::wavcontrast4(struct local_params& lp, float ** tmp, float
if (MaxP[level] > 0.f && mean[level] != 0.f && sigma[level] != 0.f) {
float insigma = 0.666f; //SD
float logmax = log(MaxP[level]); //log Max
- float rapX = (mean[level] + sigma[level]) / MaxP[level]; //rapport between sD / max
+ float rapX = (mean[level] + lp.sigmalc * sigma[level]) / MaxP[level]; //rapport between sD / max
float inx = log(insigma);
float iny = log(rapX);
float rap = inx / iny; //koef
- float asig = 0.166f / sigma[level];
+ float asig = 0.166f / (sigma[level] * lp.sigmalc);
float bsig = 0.5f - asig * mean[level];
float amean = 0.5f / mean[level];
@@ -8574,7 +8611,7 @@ void ImProcFunctions::wavcontrast4(struct local_params& lp, float ** tmp, float
float absciss;
float &val = wav_L[dir][i];
- if (fabsf(val) >= (mean[level] + sigma[level])) { //for max
+ if (fabsf(val) >= (mean[level] + lp.sigmalc * sigma[level])) { //for max
float valcour = xlogf(fabsf(val));
float valc = valcour - logmax;
float vald = valc * rap;
@@ -8672,7 +8709,7 @@ void ImProcFunctions::wavcontrast4(struct local_params& lp, float ** tmp, float
return;
}
- if (wavcurvelev && radlevblur > 0.f) {
+ if (wavcurvelev && radlevblur > 0.f && chromablu > 0.f) {
wavcont(lp, tmp, *wdspota, templevela, level_bl, maxlvl, loclevwavCurve, loclevwavutili, loccompwavCurve, loccompwavutili, loccomprewavCurve, loccomprewavutili, radlevblur, 1, chromablu, 0.f, 0.f, 0.f);
}
@@ -8727,7 +8764,7 @@ void ImProcFunctions::wavcontrast4(struct local_params& lp, float ** tmp, float
return;
}
- if (wavcurvelev && radlevblur > 0.f) {
+ if (wavcurvelev && radlevblur > 0.f && chromablu > 0.f) {
wavcont(lp, tmp, *wdspotb, templevelb, level_bl, maxlvl, loclevwavCurve, loclevwavutili, loccompwavCurve, loccompwavutili, loccomprewavCurve, loccomprewavutili, radlevblur, 1, chromablu, 0.f, 0.f, 0.f);
}
@@ -13035,7 +13072,7 @@ void ImProcFunctions::Lab_Local(int call, int sp, float** shbuffer, LabImage * o
float thr = 0.001f;
int flag = 0;
-
+
if (maxlvl <= 4) {
mL0 = 0.f;
mC0 = 0.f;
@@ -13053,7 +13090,7 @@ void ImProcFunctions::Lab_Local(int call, int sp, float** shbuffer, LabImage * o
mL0 = mL = mC0 = mC = 0.f;
}
- if (exec || compreena || comprena || levelena || lp.wavgradl) {
+ if (exec || compreena || comprena || levelena || blurena || lp.wavgradl || locwavCurve || lp.edgwena) {
bool origl = false;
// origlc = false;
LabImage *mergfile = origl ? tmpres.get() : tmp1.get();
@@ -13069,7 +13106,7 @@ void ImProcFunctions::Lab_Local(int call, int sp, float** shbuffer, LabImage * o
tmp1->b[x][y] = CLIPC((1.f + mC0) * mergfile->b[x][y] - mC * tmpresid->b[x][y]);
}
- if (softr != 0.f && (compreena || comprena || levelena || lp.wavgradl || fabs(mL) > 0.001f)) {
+ if (softr != 0.f && (compreena || locwavCurve || comprena || blurena || levelena || lp.wavgradl || lp.edgwena || fabs(mL) > 0.001f)) {
softproc(tmpres.get(), tmp1.get(), softr, bfh, bfw, 0.0001, 0.00001, thr, sk, multiThread, flag);
}
}
@@ -13094,7 +13131,7 @@ void ImProcFunctions::Lab_Local(int call, int sp, float** shbuffer, LabImage * o
JaggedArray loctemp(bfw, bfh);
if (call == 2) { //call from simpleprocess
- printf("bfw=%i bfh=%i\n", bfw, bfh);
+ // printf("bfw=%i bfh=%i\n", bfw, bfh);
if (bfw < mSPsharp || bfh < mSPsharp) {
printf("too small RT-spot - minimum size 39 * 39\n");
diff --git a/rtengine/procevents.h b/rtengine/procevents.h
index 1971e4ff6..d5becbf08 100644
--- a/rtengine/procevents.h
+++ b/rtengine/procevents.h
@@ -942,8 +942,11 @@ enum ProcEventCode {
Evlocallabresidshathr = 916,
Evlocallabresidhi = 917,
Evlocallabresidhithr = 918,
- EvlocallabcomplexityWithRefresh = 919,
- EvlocallabcomplexityWithoutRefresh = 920,
+ Evlocallabsigmalc = 919,
+ Evlocallabsigmalc2 = 920,
+ Evlocallabblwh = 921,
+ EvlocallabcomplexityWithRefresh = 922,
+ EvlocallabcomplexityWithoutRefresh = 923,
NUMOFEVENTS
};
diff --git a/rtengine/procparams.cc b/rtengine/procparams.cc
index cdd76aa60..4483c079e 100644
--- a/rtengine/procparams.cc
+++ b/rtengine/procparams.cc
@@ -2530,6 +2530,7 @@ LocallabParams::LocallabSpot::LocallabSpot() :
transitweak(1.0),
transitgrad(0.0),
avoid(false),
+ blwh(false),
recurs(false),
laplac(false),
deltae(true),
@@ -3346,6 +3347,7 @@ LocallabParams::LocallabSpot::LocallabSpot() :
lcamount(0.0),
lcdarkness(1.0),
lclightness(1.0),
+ sigmalc(1.0),
levelwav(4),
residcont(0.0),
residsha(0.0),
@@ -3362,13 +3364,14 @@ LocallabParams::LocallabSpot::LocallabSpot() :
sigmadr(1.0),
threswav(1.4),
chromalev(1.0),
- chromablu(1.0),
+ chromablu(0.0),
sigmadc(1.0),
deltad(0.0),
fatres(0.0),
clarilres(0.0),
claricres(0.0),
clarisoft(1.0),
+ sigmalc2(1.0),
strwav(0.0),
angwav(0.0),
strengthw(0.0),
@@ -3380,7 +3383,7 @@ LocallabParams::LocallabSpot::LocallabSpot() :
thigw(0.0),
edgw(60.0),
basew(10.0),
- sensilc(30),
+ sensilc(50),
fftwlc(false),
blurlc(true),
wavblur(false),
@@ -3391,7 +3394,7 @@ LocallabParams::LocallabSpot::LocallabSpot() :
wavgradl(false),
wavcompre(false),
origlc(false),
- localcontMethod("loc"),
+ localcontMethod("wav"),
localedgMethod("thr"),
localneiMethod("low"),
locwavcurve{
@@ -3651,6 +3654,7 @@ bool LocallabParams::LocallabSpot::operator ==(const LocallabSpot& other) const
&& transitweak == other.transitweak
&& transitgrad == other.transitgrad
&& avoid == other.avoid
+ && blwh == other.blwh
&& recurs == other.recurs
&& laplac == other.laplac
&& deltae == other.deltae
@@ -3974,6 +3978,7 @@ bool LocallabParams::LocallabSpot::operator ==(const LocallabSpot& other) const
&& lcamount == other.lcamount
&& lcdarkness == other.lcdarkness
&& lclightness == other.lclightness
+ && sigmalc == other.sigmalc
&& levelwav == other.levelwav
&& residcont == other.residcont
&& residsha == other.residsha
@@ -3997,6 +4002,7 @@ bool LocallabParams::LocallabSpot::operator ==(const LocallabSpot& other) const
&& clarilres == other.clarilres
&& claricres == other.claricres
&& clarisoft == other.clarisoft
+ && sigmalc2 == other.sigmalc2
&& strwav == other.strwav
&& angwav == other.angwav
&& strengthw == other.strengthw
@@ -5103,6 +5109,7 @@ int ProcParams::save(const Glib::ustring& fname, const Glib::ustring& fname2, bo
saveToKeyfile(!pedited || spot_edited->transitweak, "Locallab", "Transitweak_" + index_str, spot.transitweak, keyFile);
saveToKeyfile(!pedited || spot_edited->transitgrad, "Locallab", "Transitgrad_" + index_str, spot.transitgrad, keyFile);
saveToKeyfile(!pedited || spot_edited->avoid, "Locallab", "Avoid_" + index_str, spot.avoid, keyFile);
+ saveToKeyfile(!pedited || spot_edited->blwh, "Locallab", "Blwh_" + index_str, spot.blwh, keyFile);
saveToKeyfile(!pedited || spot_edited->recurs, "Locallab", "Recurs_" + index_str, spot.recurs, keyFile);
saveToKeyfile(!pedited || spot_edited->laplac, "Locallab", "Laplac_" + index_str, spot.laplac, keyFile);
saveToKeyfile(!pedited || spot_edited->deltae, "Locallab", "Deltae_" + index_str, spot.deltae, keyFile);
@@ -5429,6 +5436,7 @@ int ProcParams::save(const Glib::ustring& fname, const Glib::ustring& fname2, bo
saveToKeyfile(!pedited || spot_edited->lcamount, "Locallab", "Lcamount_" + index_str, spot.lcamount, keyFile);
saveToKeyfile(!pedited || spot_edited->lcdarkness, "Locallab", "Lcdarkness_" + index_str, spot.lcdarkness, keyFile);
saveToKeyfile(!pedited || spot_edited->lclightness, "Locallab", "Lclightness_" + index_str, spot.lclightness, keyFile);
+ saveToKeyfile(!pedited || spot_edited->sigmalc, "Locallab", "Sigmalc_" + index_str, spot.sigmalc, keyFile);
saveToKeyfile(!pedited || spot_edited->levelwav, "Locallab", "Levelwav_" + index_str, spot.levelwav, keyFile);
saveToKeyfile(!pedited || spot_edited->residcont, "Locallab", "Residcont_" + index_str, spot.residcont, keyFile);
saveToKeyfile(!pedited || spot_edited->residsha, "Locallab", "Residsha_" + index_str, spot.residsha, keyFile);
@@ -5452,6 +5460,7 @@ int ProcParams::save(const Glib::ustring& fname, const Glib::ustring& fname2, bo
saveToKeyfile(!pedited || spot_edited->clarilres, "Locallab", "ClariLres_" + index_str, spot.clarilres, keyFile);
saveToKeyfile(!pedited || spot_edited->claricres, "Locallab", "ClariCres_" + index_str, spot.claricres, keyFile);
saveToKeyfile(!pedited || spot_edited->clarisoft, "Locallab", "Clarisoft_" + index_str, spot.clarisoft, keyFile);
+ saveToKeyfile(!pedited || spot_edited->sigmalc2, "Locallab", "Sigmalc2_" + index_str, spot.sigmalc2, keyFile);
saveToKeyfile(!pedited || spot_edited->strwav, "Locallab", "Strwav_" + index_str, spot.strwav, keyFile);
saveToKeyfile(!pedited || spot_edited->angwav, "Locallab", "Angwav_" + index_str, spot.angwav, keyFile);
saveToKeyfile(!pedited || spot_edited->strengthw, "Locallab", "Strengthw_" + index_str, spot.strengthw, keyFile);
@@ -6704,6 +6713,7 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
assignFromKeyfile(keyFile, "Locallab", "Transitweak_" + index_str, pedited, spot.transitweak, spotEdited.transitweak);
assignFromKeyfile(keyFile, "Locallab", "Transitgrad_" + index_str, pedited, spot.transitgrad, spotEdited.transitgrad);
assignFromKeyfile(keyFile, "Locallab", "Avoid_" + index_str, pedited, spot.avoid, spotEdited.avoid);
+ assignFromKeyfile(keyFile, "Locallab", "Blwh_" + index_str, pedited, spot.blwh, spotEdited.blwh);
assignFromKeyfile(keyFile, "Locallab", "Recurs_" + index_str, pedited, spot.recurs, spotEdited.recurs);
assignFromKeyfile(keyFile, "Locallab", "Laplac_" + index_str, pedited, spot.laplac, spotEdited.laplac);
assignFromKeyfile(keyFile, "Locallab", "Deltae_" + index_str, pedited, spot.deltae, spotEdited.deltae);
@@ -7093,6 +7103,7 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
assignFromKeyfile(keyFile, "Locallab", "Lcamount_" + index_str, pedited, spot.lcamount, spotEdited.lcamount);
assignFromKeyfile(keyFile, "Locallab", "Lcdarkness_" + index_str, pedited, spot.lcdarkness, spotEdited.lcdarkness);
assignFromKeyfile(keyFile, "Locallab", "Lclightness_" + index_str, pedited, spot.lclightness, spotEdited.lclightness);
+ assignFromKeyfile(keyFile, "Locallab", "Sigmalc_" + index_str, pedited, spot.sigmalc, spotEdited.sigmalc);
assignFromKeyfile(keyFile, "Locallab", "Levelwav_" + index_str, pedited, spot.levelwav, spotEdited.levelwav);
assignFromKeyfile(keyFile, "Locallab", "Residcont_" + index_str, pedited, spot.residcont, spotEdited.residcont);
assignFromKeyfile(keyFile, "Locallab", "Residsha_" + index_str, pedited, spot.residsha, spotEdited.residsha);
@@ -7116,6 +7127,7 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
assignFromKeyfile(keyFile, "Locallab", "ClariLres_" + index_str, pedited, spot.clarilres, spotEdited.clarilres);
assignFromKeyfile(keyFile, "Locallab", "ClariCres_" + index_str, pedited, spot.claricres, spotEdited.claricres);
assignFromKeyfile(keyFile, "Locallab", "Clarisoft_" + index_str, pedited, spot.clarisoft, spotEdited.clarisoft);
+ assignFromKeyfile(keyFile, "Locallab", "Sigmalc2_" + index_str, pedited, spot.sigmalc2, spotEdited.sigmalc2);
assignFromKeyfile(keyFile, "Locallab", "Strwav_" + index_str, pedited, spot.strwav, spotEdited.strwav);
assignFromKeyfile(keyFile, "Locallab", "Angwav_" + index_str, pedited, spot.angwav, spotEdited.angwav);
assignFromKeyfile(keyFile, "Locallab", "Strengthw_" + index_str, pedited, spot.strengthw, spotEdited.strengthw);
diff --git a/rtengine/procparams.h b/rtengine/procparams.h
index a1320ee5a..840eef911 100644
--- a/rtengine/procparams.h
+++ b/rtengine/procparams.h
@@ -985,6 +985,7 @@ struct LocallabParams {
double transitweak;
double transitgrad;
bool avoid;
+ bool blwh;
bool recurs;
bool laplac;
bool deltae;
@@ -1300,6 +1301,7 @@ struct LocallabParams {
double lcamount;
double lcdarkness;
double lclightness;
+ double sigmalc;
int levelwav;
double residcont;
double residsha;
@@ -1323,6 +1325,7 @@ struct LocallabParams {
double clarilres;
double claricres;
double clarisoft;
+ double sigmalc2;
double strwav;
double angwav;
double strengthw;
diff --git a/rtengine/refreshmap.cc b/rtengine/refreshmap.cc
index c8654568d..f408d6628 100644
--- a/rtengine/refreshmap.cc
+++ b/rtengine/refreshmap.cc
@@ -946,6 +946,9 @@ int refreshmap[rtengine::NUMOFEVENTS] = {
LUMINANCECURVE, // Evlocallabresidshathr
LUMINANCECURVE, // Evlocallabresidhi
LUMINANCECURVE, // Evlocallabresidhithr
+ LUMINANCECURVE, // Evlocallabsigmalc
+ LUMINANCECURVE, // Evlocallabsigmalc2
+ LUMINANCECURVE, // Evlocallabblwh
LUMINANCECURVE, // EvlocallabcomplexityWithRefresh
M_VOID // EvlocallabcomplexityWithoutRefresh
};
diff --git a/rtgui/controlspotpanel.cc b/rtgui/controlspotpanel.cc
index ea7ead200..c9c6b1a54 100644
--- a/rtgui/controlspotpanel.cc
+++ b/rtgui/controlspotpanel.cc
@@ -78,6 +78,7 @@ ControlSpotPanel::ControlSpotPanel():
lumask_(Gtk::manage(new Adjuster(M("TP_LOCALLAB_LUMASK"), 0, 30, 1, 10))),
avoid_(Gtk::manage(new Gtk::CheckButton(M("TP_LOCALLAB_AVOID")))),
+ blwh_(Gtk::manage(new Gtk::CheckButton(M("TP_LOCALLAB_BLWH")))),
recurs_(Gtk::manage(new Gtk::CheckButton(M("TP_LOCALLAB_RECURS")))),
laplac_(Gtk::manage(new Gtk::CheckButton(M("TP_LOCALLAB_LAPLACC")))),
deltae_(Gtk::manage(new Gtk::CheckButton(M("TP_LOCALLAB_DELTAEC")))),
@@ -344,6 +345,15 @@ ControlSpotPanel::ControlSpotPanel():
sigc::mem_fun(*this, &ControlSpotPanel::avoidChanged));
pack_start(*avoid_);
+ blwhConn_ = blwh_->signal_toggled().connect(
+ sigc::mem_fun(*this, &ControlSpotPanel::blwhChanged));
+
+ if (showtooltip) {
+ blwh_->set_tooltip_text(M("TP_LOCALLAB_BLWH_TOOLTIP"));
+ }
+
+ pack_start(*blwh_);
+
recursConn_ = recurs_->signal_toggled().connect(
sigc::mem_fun(*this, &ControlSpotPanel::recursChanged));
@@ -741,6 +751,7 @@ void ControlSpotPanel::load_ControlSpot_param()
balanh_->setValue((double)row[spots_.balanh]);
colorde_->setValue((double)row[spots_.colorde]);
avoid_->set_active(row[spots_.avoid]);
+ blwh_->set_active(row[spots_.blwh]);
recurs_->set_active(row[spots_.recurs]);
laplac_->set_active(row[spots_.laplac]);
deltae_->set_active(row[spots_.deltae]);
@@ -1291,6 +1302,31 @@ void ControlSpotPanel::avoidChanged()
}
}
+void ControlSpotPanel::blwhChanged()
+{
+ // printf("blwhChanged\n");
+
+ // Get selected control spot
+ const auto s = treeview_->get_selection();
+
+ if (!s->count_selected_rows()) {
+ return;
+ }
+
+ const auto iter = s->get_selected();
+ Gtk::TreeModel::Row row = *iter;
+ row[spots_.blwh] = blwh_->get_active();
+
+ // Raise event
+ if (listener) {
+ if (blwh_->get_active()) {
+ listener->panelChanged(Evlocallabblwh, M("GENERAL_ENABLED"));
+ } else {
+ listener->panelChanged(Evlocallabblwh, M("GENERAL_DISABLED"));
+ }
+ }
+}
+
void ControlSpotPanel::recursChanged()
{
// printf("recursChanged\n");
@@ -1451,6 +1487,7 @@ void ControlSpotPanel::disableParamlistener(bool cond)
balanh_->block(cond);
colorde_->block(cond);
avoidConn_.block(cond);
+ blwhConn_.block(cond);
recursConn_.block(cond);
laplacConn_.block(cond);
deltaeConn_.block(cond);
@@ -1490,6 +1527,7 @@ void ControlSpotPanel::setParamEditable(bool cond)
balanh_->set_sensitive(cond);
colorde_->set_sensitive(cond);
avoid_->set_sensitive(cond);
+ blwh_->set_sensitive(cond);
recurs_->set_sensitive(cond);
laplac_->set_sensitive(cond);
deltae_->set_sensitive(cond);
@@ -2140,6 +2178,7 @@ ControlSpotPanel::SpotRow* ControlSpotPanel::getSpot(const int index)
r->scopemask = row[spots_.scopemask];
r->lumask = row[spots_.lumask];
r->avoid = row[spots_.avoid];
+ r->blwh = row[spots_.blwh];
r->recurs = row[spots_.recurs];
r->laplac = row[spots_.laplac];
r->deltae = row[spots_.deltae];
@@ -2254,6 +2293,7 @@ void ControlSpotPanel::addControlSpot(SpotRow* newSpot)
row[spots_.balanh] = newSpot->balanh;
row[spots_.colorde] = newSpot->colorde;
row[spots_.avoid] = newSpot->avoid;
+ row[spots_.blwh] = newSpot->blwh;
row[spots_.recurs] = newSpot->recurs;
row[spots_.laplac] = newSpot->laplac;
row[spots_.deltae] = newSpot->deltae;
@@ -2363,6 +2403,7 @@ ControlSpotPanel::ControlSpots::ControlSpots()
add(balanh);
add(colorde);
add(avoid);
+ add(blwh);
add(recurs);
add(laplac);
add(deltae);
diff --git a/rtgui/controlspotpanel.h b/rtgui/controlspotpanel.h
index 0ae41e91b..02a4758c1 100644
--- a/rtgui/controlspotpanel.h
+++ b/rtgui/controlspotpanel.h
@@ -64,6 +64,7 @@ public:
double balanh;
double colorde;
bool avoid;
+ bool blwh;
bool recurs;
bool laplac;
bool deltae;
@@ -208,6 +209,7 @@ private:
void adjusterChanged(Adjuster* a, double newval);
void avoidChanged();
+ void blwhChanged();
void recursChanged();
void laplacChanged();
void deltaeChanged();
@@ -262,6 +264,7 @@ private:
Gtk::TreeModelColumn balanh;
Gtk::TreeModelColumn colorde;
Gtk::TreeModelColumn avoid;
+ Gtk::TreeModelColumn blwh;
Gtk::TreeModelColumn recurs;
Gtk::TreeModelColumn laplac;
Gtk::TreeModelColumn deltae;
@@ -346,6 +349,8 @@ private:
Gtk::CheckButton* const avoid_;
sigc::connection avoidConn_;
+ Gtk::CheckButton* const blwh_;
+ sigc::connection blwhConn_;
Gtk::CheckButton* const recurs_;
sigc::connection recursConn_;
Gtk::CheckButton* const laplac_;
diff --git a/rtgui/locallab.cc b/rtgui/locallab.cc
index ec30bb29a..f70d10cbb 100644
--- a/rtgui/locallab.cc
+++ b/rtgui/locallab.cc
@@ -293,6 +293,7 @@ void Locallab::read(const rtengine::procparams::ProcParams* pp, const ParamsEdit
r->balanh = pp->locallab.spots.at(i).balanh;
r->colorde = pp->locallab.spots.at(i).colorde;
r->avoid = pp->locallab.spots.at(i).avoid;
+ r->blwh = pp->locallab.spots.at(i).blwh;
r->recurs = pp->locallab.spots.at(i).recurs;
r->laplac = pp->locallab.spots.at(i).laplac;
r->deltae = pp->locallab.spots.at(i).deltae;
@@ -461,6 +462,7 @@ void Locallab::write(rtengine::procparams::ProcParams* pp, ParamsEdited* pedited
r->balanh = newSpot->balanh;
r->colorde = newSpot->colorde;
r->avoid = newSpot->avoid;
+ r->blwh = newSpot->blwh;
r->recurs = newSpot->recurs;
r->laplac = newSpot->laplac;
r->deltae = newSpot->deltae;
@@ -745,6 +747,7 @@ void Locallab::write(rtengine::procparams::ProcParams* pp, ParamsEdited* pedited
r->balanh = newSpot->balanh;
r->colorde = newSpot->colorde;
r->avoid = newSpot->avoid;
+ r->blwh = newSpot->blwh;
r->recurs = newSpot->recurs;
r->laplac = newSpot->laplac;
r->deltae = newSpot->deltae;
@@ -886,6 +889,7 @@ void Locallab::write(rtengine::procparams::ProcParams* pp, ParamsEdited* pedited
pp->locallab.spots.at(pp->locallab.selspot).balanh = r->balanh;
pp->locallab.spots.at(pp->locallab.selspot).colorde = r->colorde;
pp->locallab.spots.at(pp->locallab.selspot).avoid = r->avoid;
+ pp->locallab.spots.at(pp->locallab.selspot).blwh = r->blwh;
pp->locallab.spots.at(pp->locallab.selspot).recurs = r->recurs;
pp->locallab.spots.at(pp->locallab.selspot).laplac = r->laplac;
pp->locallab.spots.at(pp->locallab.selspot).deltae = r->deltae;
diff --git a/rtgui/locallabtools.cc b/rtgui/locallabtools.cc
index 5f79d9713..a1adc13a2 100644
--- a/rtgui/locallabtools.cc
+++ b/rtgui/locallabtools.cc
@@ -368,7 +368,7 @@ void LocallabTool::complexityModeChanged()
// Raise event with refreshing
if (listener) {
listener->panelChanged(EvlocallabcomplexityWithRefresh,
- M("TP_LOCALLAB_MODE_NORMAL") + " (" + escapeHtmlChars(spotName) + ")");
+ M("TP_LOCALLAB_MODE_NORMAL") + " (" + escapeHtmlChars(spotName) + ")");
}
} else { // New selected mode is Expert one
// Update GUI based on new mode
@@ -377,7 +377,7 @@ void LocallabTool::complexityModeChanged()
// Raise event without refreshing
if (listener) {
listener->panelChanged(EvlocallabcomplexityWithoutRefresh,
- M("TP_LOCALLAB_MODE_EXPERT") + " (" + escapeHtmlChars(spotName) + ")");
+ M("TP_LOCALLAB_MODE_EXPERT") + " (" + escapeHtmlChars(spotName) + ")");
}
}
}
diff --git a/rtgui/locallabtools.h b/rtgui/locallabtools.h
index c9e22f948..239ccc997 100644
--- a/rtgui/locallabtools.h
+++ b/rtgui/locallabtools.h
@@ -914,6 +914,7 @@ private:
Adjuster* const lcamount;
Adjuster* const lcdarkness;
Adjuster* const lclightness;
+ Adjuster* const sigmalc;
CurveEditorGroup* const LocalcurveEditorwav;
FlatCurveEditor* const wavshape;
Adjuster* const levelwav;
@@ -935,6 +936,7 @@ private:
MyExpander* const expcontrastpyr;
Gtk::Frame* const gradwavFrame;
Gtk::CheckButton* const wavgradl;
+ Adjuster* const sigmalc2;
Adjuster* const strwav;
Adjuster* const angwav;
Gtk::Frame* const edgFrame;
diff --git a/rtgui/locallabtools2.cc b/rtgui/locallabtools2.cc
index 8660eb630..2553336de 100644
--- a/rtgui/locallabtools2.cc
+++ b/rtgui/locallabtools2.cc
@@ -2045,6 +2045,7 @@ LocallabContrast::LocallabContrast():
lcamount(Gtk::manage(new Adjuster(M("TP_LOCALCONTRAST_AMOUNT"), 0, 1.0, 0.01, 0))),
lcdarkness(Gtk::manage(new Adjuster(M("TP_LOCALCONTRAST_DARKNESS"), 0, 3.0, 0.01, 1.0))),
lclightness(Gtk::manage(new Adjuster(M("TP_LOCALCONTRAST_LIGHTNESS"), 0, 3.0, 0.01, 1.0))),
+ sigmalc(Gtk::manage(new Adjuster(M("TP_LOCALLAB_SIGMAWAV"), 0.2, 2.5, 0.01, 1.))),
LocalcurveEditorwav(new CurveEditorGroup(options.lastlocalCurvesDir, M("TP_LOCALLAB_WAV"))),
wavshape(static_cast(LocalcurveEditorwav->addCurve(CT_Flat, "", nullptr, false, false))),
levelwav(Gtk::manage(new Adjuster(M("TP_LOCALLAB_LEVELWAV"), 1, 9, 1, 4))),
@@ -2057,7 +2058,7 @@ LocallabContrast::LocallabContrast():
residshathr(Gtk::manage(new Adjuster(M("TP_LOCALLAB_RESIDSHATHR"), 0., 100., 1., 30.))),
residhi(Gtk::manage(new Adjuster(M("TP_LOCALLAB_RESIDHI"), -100., 100., 1., 0.))),
residhithr(Gtk::manage(new Adjuster(M("TP_LOCALLAB_RESIDHITHR"), 0., 100., 1., 70.))),
- sensilc(Gtk::manage(new Adjuster(M("TP_LOCALLAB_SENSIS"), 0, 100, 1, 30))),
+ sensilc(Gtk::manage(new Adjuster(M("TP_LOCALLAB_SENSIS"), 0, 100, 1, 50))),
clariFrame(Gtk::manage(new Gtk::Frame(M("TP_LOCALLAB_CLARIFRA")))),
clarilres(Gtk::manage(new Adjuster(M("TP_LOCALLAB_CLARILRES"), -20., 100., 0.5, 0.))),
claricres(Gtk::manage(new Adjuster(M("TP_LOCALLAB_CLARICRES"), -20., 100., 0.5, 0.))),
@@ -2066,6 +2067,7 @@ LocallabContrast::LocallabContrast():
expcontrastpyr(Gtk::manage(new MyExpander(false, Gtk::manage(new Gtk::HBox())))),
gradwavFrame(Gtk::manage(new Gtk::Frame(M("TP_LOCALLAB_GRADWAVFRA")))),
wavgradl(Gtk::manage(new Gtk::CheckButton(M("TP_LOCALLAB_GRALWFRA")))),
+ sigmalc2(Gtk::manage(new Adjuster(M("TP_LOCALLAB_SIGMAWAV"), 0.2, 2.5, 0.01, 1.))),
strwav(Gtk::manage(new Adjuster(M("TP_LOCALLAB_GRADSTR"), -4.0, 4.0, 0.05, 0.))),
angwav(Gtk::manage(new Adjuster(M("TP_LOCALLAB_GRADANG"), -180, 180, 0.1, 0.))),
edgFrame(Gtk::manage(new Gtk::Frame(M("TP_LOCALLAB_EDGSHARPFRA")))),
@@ -2091,7 +2093,7 @@ LocallabContrast::LocallabContrast():
wavblur(Gtk::manage(new Gtk::CheckButton(M("TP_LOCALLAB_BLURLEVELFRA")))),
levelblur(Gtk::manage(new Adjuster(M("TP_LOCALLAB_LEVELBLUR"), 0., 100., 0.5, 0.))),
sigmabl(Gtk::manage(new Adjuster(M("TP_LOCALLAB_SIGMAWAV"), 0.2, 2.5, 0.01, 1.))),
- chromablu(Gtk::manage(new Adjuster(M("TP_LOCALLAB_CHROMABLU"), 0.01, 5., 0.01, 1.))),
+ chromablu(Gtk::manage(new Adjuster(M("TP_LOCALLAB_CHROMABLU"), 0.0, 5., 0.1, 0.))),
LocalcurveEditorwavlev(new CurveEditorGroup(options.lastlocalCurvesDir, M("TP_LOCALLAB_WAVLEV"))),
wavshapelev(static_cast(LocalcurveEditorwavlev->addCurve(CT_Flat, "", nullptr, false, false))),
residblur(Gtk::manage(new Adjuster(M("TP_LOCALLAB_RESIDBLUR"), 0., 100., 0.5, 0.))),
@@ -2101,7 +2103,7 @@ LocallabContrast::LocallabContrast():
wavcont(Gtk::manage(new Gtk::CheckButton(M("TP_LOCALLAB_CONTFRA")))),
sigma(Gtk::manage(new Adjuster(M("TP_LOCALLAB_SIGMAWAV"), 0.2, 2.5, 0.01, 1.))),
offset(Gtk::manage(new Adjuster(M("TP_LOCALLAB_OFFSETWAV"), 0.33, 1.66, 0.01, 1., Gtk::manage(new RTImage("circle-black-small.png")), Gtk::manage(new RTImage("circle-white-small.png"))))),
- chromalev(Gtk::manage(new Adjuster(M("TP_LOCALLAB_CHROMALEV"), 0.01, 5., 0.01, 1.))),
+ chromalev(Gtk::manage(new Adjuster(M("TP_LOCALLAB_CHROMALEV"), 0.1, 5., 0.1, 1.))),
LocalcurveEditorwavcon(new CurveEditorGroup(options.lastlocalCurvesDir, M("TP_LOCALLAB_WAVCON"))),
wavshapecon(static_cast(LocalcurveEditorwavcon->addCurve(CT_Flat, "", nullptr, false, false))),
compreFrame(Gtk::manage(new Gtk::Frame(M("TP_LOCALLAB_COMPREFRA")))),
@@ -2153,6 +2155,7 @@ LocallabContrast::LocallabContrast():
lcdarkness->setAdjusterListener(this);
lclightness->setAdjusterListener(this);
+ sigmalc->setAdjusterListener(this);
LocalcurveEditorwav->setCurveListener(this);
@@ -2177,11 +2180,13 @@ LocallabContrast::LocallabContrast():
LresTitleHBox->pack_start(*LresLabel, Gtk::PACK_EXPAND_WIDGET, 0);
expresidpyr->setLabel(LresTitleHBox);
setExpandAlignProperties(expresidpyr, true, false, Gtk::ALIGN_FILL, Gtk::ALIGN_START);
-
+
residcont->setAdjusterListener(this);
residchro->setAdjusterListener(this);
+ shresFrame->set_label_align(0.025, 0.5);
+
residsha->setAdjusterListener(this);
residshathr->setAdjusterListener(this);
@@ -2223,6 +2228,8 @@ LocallabContrast::LocallabContrast():
wavgradlConn = wavgradl->signal_toggled().connect(sigc::mem_fun(*this, &LocallabContrast::wavgradlChanged));
+ sigmalc2->setAdjusterListener(this);
+
strwav->setAdjusterListener(this);
angwav->setAdjusterListener(this);
@@ -2313,6 +2320,11 @@ LocallabContrast::LocallabContrast():
chromalev->setAdjusterListener(this);
+ if (showtooltip) {
+ chromalev->set_tooltip_text(M("TP_LOCALLAB_CHROMABLU_TOOLTIP"));
+ chromablu->set_tooltip_text(M("TP_LOCALLAB_CHROMABLU_TOOLTIP"));
+ }
+
LocalcurveEditorwavcon->setCurveListener(this);
wavshapecon->setIdentityValue(0.);
@@ -2345,10 +2357,6 @@ LocallabContrast::LocallabContrast():
wavcompConn = wavcomp->signal_toggled().connect(sigc::mem_fun(*this, &LocallabContrast::wavcompChanged));
- if (showtooltip) {
- // sigmadc->set_tooltip_text(M("TP_LOCALLAB_COMPFRAME_TOOLTIP"));
- }
-
sigmadc->setAdjusterListener(this);
deltad->setAdjusterListener(this);
@@ -2444,11 +2452,11 @@ LocallabContrast::LocallabContrast():
// Add Local contrast specific widgets to GUI
pack_start(*localcontMethod);
- shresFrame->set_label_align(0.025, 0.5);
pack_start(*lcradius);
pack_start(*lcamount);
pack_start(*lcdarkness);
pack_start(*lclightness);
+ pack_start(*sigmalc);
pack_start(*LocalcurveEditorwav, Gtk::PACK_SHRINK, 4); // Padding is mandatory to correct behavior of curve editor
// pack_start(*levelwav);
pack_start(*csThreshold);
@@ -2477,6 +2485,7 @@ LocallabContrast::LocallabContrast():
ToolParamBlock* const blurcontBox = Gtk::manage(new ToolParamBlock());
gradwavFrame->set_label_widget(*wavgradl);
ToolParamBlock* const gradwavBox = Gtk::manage(new ToolParamBlock());
+ gradwavBox->pack_start(*sigmalc2);
gradwavBox->pack_start(*strwav);
gradwavBox->pack_start(*angwav);
gradwavFrame->add(*gradwavBox);
@@ -2668,6 +2677,7 @@ void LocallabContrast::read(const rtengine::procparams::ProcParams* pp, const Pa
lcamount->setValue(pp->locallab.spots.at(index).lcamount);
lcdarkness->setValue(pp->locallab.spots.at(index).lcdarkness);
lclightness->setValue(pp->locallab.spots.at(index).lclightness);
+ sigmalc->setValue(pp->locallab.spots.at(index).sigmalc);
wavshape->setCurve(pp->locallab.spots.at(index).locwavcurve);
levelwav->setValue((double)pp->locallab.spots.at(index).levelwav);
csThreshold->setValue(pp->locallab.spots.at(index).csthreshold);
@@ -2683,6 +2693,7 @@ void LocallabContrast::read(const rtengine::procparams::ProcParams* pp, const Pa
clarisoft->setValue(pp->locallab.spots.at(index).clarisoft);
origlc->set_active(pp->locallab.spots.at(index).origlc);
wavgradl->set_active(pp->locallab.spots.at(index).wavgradl);
+ sigmalc2->setValue(pp->locallab.spots.at(index).sigmalc2);
strwav->setValue(pp->locallab.spots.at(index).strwav);
angwav->setValue(pp->locallab.spots.at(index).angwav);
wavedg->set_active(pp->locallab.spots.at(index).wavedg);
@@ -2785,6 +2796,7 @@ void LocallabContrast::write(rtengine::procparams::ProcParams* pp, ParamsEdited*
pp->locallab.spots.at(index).lcamount = lcamount->getValue();
pp->locallab.spots.at(index).lcdarkness = lcdarkness->getValue();
pp->locallab.spots.at(index).lclightness = lclightness->getValue();
+ pp->locallab.spots.at(index).sigmalc = sigmalc->getValue();
pp->locallab.spots.at(index).locwavcurve = wavshape->getCurve();
pp->locallab.spots.at(index).levelwav = levelwav->getIntValue();
pp->locallab.spots.at(index).csthreshold = csThreshold->getValue();
@@ -2800,6 +2812,7 @@ void LocallabContrast::write(rtengine::procparams::ProcParams* pp, ParamsEdited*
pp->locallab.spots.at(index).clarisoft = clarisoft->getValue();
pp->locallab.spots.at(index).origlc = origlc->get_active();
pp->locallab.spots.at(index).wavgradl = wavgradl->get_active();
+ pp->locallab.spots.at(index).sigmalc2 = sigmalc2->getValue();
pp->locallab.spots.at(index).strwav = strwav->getValue();
pp->locallab.spots.at(index).angwav = angwav->getValue();
pp->locallab.spots.at(index).wavedg = wavedg->get_active();
@@ -2880,6 +2893,7 @@ void LocallabContrast::setDefaults(const rtengine::procparams::ProcParams* defPa
lcamount->setDefault(defSpot.lcamount);
lcdarkness->setDefault(defSpot.lcdarkness);
lclightness->setDefault(defSpot.lclightness);
+ sigmalc->setDefault(defSpot.sigmalc);
levelwav->setDefault((double)defSpot.levelwav);
csThreshold->setDefault(defSpot.csthreshold);
residcont->setDefault(defSpot.residcont);
@@ -2892,6 +2906,7 @@ void LocallabContrast::setDefaults(const rtengine::procparams::ProcParams* defPa
clarilres->setDefault(defSpot.clarilres);
claricres->setDefault(defSpot.claricres);
clarisoft->setDefault(defSpot.clarisoft);
+ sigmalc2->setDefault(defSpot.sigmalc2);
strwav->setDefault(defSpot.strwav);
angwav->setDefault(defSpot.angwav);
strengthw->setDefault(defSpot.strengthw);
@@ -2955,6 +2970,13 @@ void LocallabContrast::adjusterChanged(Adjuster* a, double newval)
}
}
+ if (a == sigmalc) {
+ if (listener) {
+ listener->panelChanged(Evlocallabsigmalc,
+ sigmalc->getTextValue() + " (" + escapeHtmlChars(spotName) + ")");
+ }
+ }
+
if (a == levelwav) {
if (listener) {
listener->panelChanged(Evlocallablevelwav,
@@ -3032,6 +3054,13 @@ void LocallabContrast::adjusterChanged(Adjuster* a, double newval)
}
}
+ if (a == sigmalc2) {
+ if (listener) {
+ listener->panelChanged(Evlocallabsigmalc2,
+ sigmalc2->getTextValue() + " (" + escapeHtmlChars(spotName) + ")");
+ }
+ }
+
if (a == strwav) {
if (listener) {
listener->panelChanged(Evlocallabstrwav,
@@ -3603,92 +3632,28 @@ void LocallabContrast::updateContrastGUI1()
lcamount->show();
lcdarkness->show();
lclightness->show();
+ sigmalc->hide();
LocalcurveEditorwav->hide();
levelwav->hide();
csThreshold->hide();
- residcont->hide();
- residchro->hide();
- residsha->hide();
- residshathr->hide();
- residhi->hide();
- residhithr->hide();
- shresFrame->hide();
+ expresidpyr->hide();
clariFrame->hide();
- strwav->hide();
- angwav->hide();
- strengthw->hide();
- sigmaed->hide();
- LocalcurveEditorwavedg->hide();
- gradw->hide();
- radiusw->hide();
- detailw->hide();
- tloww->hide();
- thigw->hide();
- edgw->hide();
- basew->hide();
- levelblur->hide();
- sigmabl->hide();
- chromablu->hide();
- LocalcurveEditorwavlev->hide();
- residblur->hide();
- sigma->hide();
- offset->hide();
- chromalev->hide();
- LocalcurveEditorwavcon->hide();
- LocalcurveEditorwavcompre->hide();
- sigmadr->hide();
- threswav->hide();
- residcomp->hide();
- sigmadc->hide();
- deltad->hide();
- LocalcurveEditorwavcomp->hide();
- fatres->hide();
+ expcontrastpyr->hide();
+ expcontrastpyr2->hide();
fftwlc->show();
} else if (localcontMethod->get_active_row_number() == 1) {
lcradius->hide();
lcamount->hide();
lcdarkness->hide();
lclightness->hide();
+ sigmalc->show();
LocalcurveEditorwav->show();
levelwav->show();
csThreshold->show();
- residcont->show();
- residchro->show();
- residsha->show();
- residshathr->show();
- residhi->show();
- residhithr->show();
- shresFrame->show();
+ expresidpyr->show();
clariFrame->show();
- strwav->show();
- angwav->show();
- strengthw->show();
- sigmaed->show();
- LocalcurveEditorwavedg->show();
- gradw->show();
- radiusw->show();
- detailw->show();
- tloww->show();
- thigw->show();
- edgw->show();
- basew->show();
- levelblur->show();
- sigmabl->show();
- chromablu->show();
- LocalcurveEditorwavlev->show();
- residblur->show();
- sigma->show();
- offset->show();
- chromalev->show();
- LocalcurveEditorwavcon->show();
- LocalcurveEditorwavcompre->show();
- sigmadr->show();
- threswav->show();
- residcomp->show();
- sigmadc->show();
- deltad->show();
- LocalcurveEditorwavcomp->show();
- fatres->show();
+ expcontrastpyr->show();
+ expcontrastpyr2->show();
fftwlc->hide();
}
}
diff --git a/rtgui/paramsedited.cc b/rtgui/paramsedited.cc
index a5c8138d3..30c1da3eb 100644
--- a/rtgui/paramsedited.cc
+++ b/rtgui/paramsedited.cc
@@ -1009,6 +1009,7 @@ void ParamsEdited::initFrom(const std::vector&
locallab.spots.at(j).transitweak = locallab.spots.at(j).transitweak && pSpot.transitweak == otherSpot.transitweak;
locallab.spots.at(j).transitgrad = locallab.spots.at(j).transitgrad && pSpot.transitgrad == otherSpot.transitgrad;
locallab.spots.at(j).avoid = locallab.spots.at(j).avoid && pSpot.avoid == otherSpot.avoid;
+ locallab.spots.at(j).blwh = locallab.spots.at(j).blwh && pSpot.blwh == otherSpot.blwh;
locallab.spots.at(j).recurs = locallab.spots.at(j).recurs && pSpot.recurs == otherSpot.recurs;
locallab.spots.at(j).laplac = locallab.spots.at(j).laplac && pSpot.laplac == otherSpot.laplac;
locallab.spots.at(j).deltae = locallab.spots.at(j).deltae && pSpot.deltae == otherSpot.deltae;
@@ -1328,6 +1329,7 @@ void ParamsEdited::initFrom(const std::vector&
locallab.spots.at(j).lcamount = locallab.spots.at(j).lcamount && pSpot.lcamount == otherSpot.lcamount;
locallab.spots.at(j).lcdarkness = locallab.spots.at(j).lcdarkness && pSpot.lcdarkness == otherSpot.lcdarkness;
locallab.spots.at(j).lclightness = locallab.spots.at(j).lclightness && pSpot.lclightness == otherSpot.lclightness;
+ locallab.spots.at(j).sigmalc = locallab.spots.at(j).sigmalc && pSpot.sigmalc == otherSpot.sigmalc;
locallab.spots.at(j).levelwav = locallab.spots.at(j).levelwav && pSpot.levelwav == otherSpot.levelwav;
locallab.spots.at(j).residcont = locallab.spots.at(j).residcont && pSpot.residcont == otherSpot.residcont;
locallab.spots.at(j).residsha = locallab.spots.at(j).residsha && pSpot.residsha == otherSpot.residsha;
@@ -1351,6 +1353,7 @@ void ParamsEdited::initFrom(const std::vector&
locallab.spots.at(j).clarilres = locallab.spots.at(j).clarilres && pSpot.clarilres == otherSpot.clarilres;
locallab.spots.at(j).claricres = locallab.spots.at(j).claricres && pSpot.claricres == otherSpot.claricres;
locallab.spots.at(j).clarisoft = locallab.spots.at(j).clarisoft && pSpot.clarisoft == otherSpot.clarisoft;
+ locallab.spots.at(j).sigmalc2 = locallab.spots.at(j).sigmalc2 && pSpot.sigmalc2 == otherSpot.sigmalc2;
locallab.spots.at(j).strwav = locallab.spots.at(j).strwav && pSpot.strwav == otherSpot.strwav;
locallab.spots.at(j).angwav = locallab.spots.at(j).angwav && pSpot.angwav == otherSpot.angwav;
locallab.spots.at(j).strengthw = locallab.spots.at(j).strengthw && pSpot.strengthw == otherSpot.strengthw;
@@ -3017,6 +3020,10 @@ void ParamsEdited::combine(rtengine::procparams::ProcParams& toEdit, const rteng
toEdit.locallab.spots.at(i).avoid = mods.locallab.spots.at(i).avoid;
}
+ if (locallab.spots.at(i).blwh) {
+ toEdit.locallab.spots.at(i).blwh = mods.locallab.spots.at(i).blwh;
+ }
+
if (locallab.spots.at(i).recurs) {
toEdit.locallab.spots.at(i).recurs = mods.locallab.spots.at(i).recurs;
}
@@ -4249,6 +4256,10 @@ void ParamsEdited::combine(rtengine::procparams::ProcParams& toEdit, const rteng
toEdit.locallab.spots.at(i).lclightness = mods.locallab.spots.at(i).lclightness;
}
+ if (locallab.spots.at(i).sigmalc) {
+ toEdit.locallab.spots.at(i).sigmalc = mods.locallab.spots.at(i).sigmalc;
+ }
+
if (locallab.spots.at(i).levelwav) {
toEdit.locallab.spots.at(i).levelwav = mods.locallab.spots.at(i).levelwav;
}
@@ -4342,6 +4353,10 @@ void ParamsEdited::combine(rtengine::procparams::ProcParams& toEdit, const rteng
toEdit.locallab.spots.at(i).clarisoft = mods.locallab.spots.at(i).clarisoft;
}
+ if (locallab.spots.at(i).sigmalc2) {
+ toEdit.locallab.spots.at(i).sigmalc2 = mods.locallab.spots.at(i).sigmalc2;
+ }
+
if (locallab.spots.at(i).strwav) {
toEdit.locallab.spots.at(i).strwav = mods.locallab.spots.at(i).strwav;
}
@@ -5748,6 +5763,7 @@ LocallabParamsEdited::LocallabSpotEdited::LocallabSpotEdited(bool v) :
transitweak(v),
transitgrad(v),
avoid(v),
+ blwh(v),
recurs(v),
laplac(v),
deltae(v),
@@ -6063,6 +6079,7 @@ LocallabParamsEdited::LocallabSpotEdited::LocallabSpotEdited(bool v) :
lcamount(v),
lcdarkness(v),
lclightness(v),
+ sigmalc(v),
levelwav(v),
residcont(v),
residsha(v),
@@ -6086,6 +6103,7 @@ LocallabParamsEdited::LocallabSpotEdited::LocallabSpotEdited(bool v) :
clarilres(v),
claricres(v),
clarisoft(v),
+ sigmalc2(v),
strwav(v),
angwav(v),
strengthw(v),
@@ -6194,6 +6212,7 @@ void LocallabParamsEdited::LocallabSpotEdited::set(bool v)
transitweak = v;
transitgrad = v;
avoid = v;
+ blwh = v;
recurs = v;
laplac = v;
deltae = v;
@@ -6513,6 +6532,7 @@ void LocallabParamsEdited::LocallabSpotEdited::set(bool v)
lcamount = v;
lcdarkness = v;
lclightness = v;
+ sigmalc = v;
levelwav = v;
residcont = v;
residsha = v;
@@ -6536,6 +6556,7 @@ void LocallabParamsEdited::LocallabSpotEdited::set(bool v)
clarilres = v;
claricres = v;
clarisoft = v;
+ sigmalc2 = v;
strwav = v;
angwav = v;
strengthw = v;
diff --git a/rtgui/paramsedited.h b/rtgui/paramsedited.h
index 2149bea02..9339e05ec 100644
--- a/rtgui/paramsedited.h
+++ b/rtgui/paramsedited.h
@@ -413,6 +413,7 @@ public:
bool transitweak;
bool transitgrad;
bool avoid;
+ bool blwh;
bool recurs;
bool laplac;
bool deltae;
@@ -728,6 +729,7 @@ public:
bool lcamount;
bool lcdarkness;
bool lclightness;
+ bool sigmalc;
bool levelwav;
bool residcont;
bool residsha;
@@ -751,6 +753,7 @@ public:
bool clarilres;
bool claricres;
bool clarisoft;
+ bool sigmalc2;
bool strwav;
bool angwav;
bool strengthw;
diff --git a/rtgui/rtwindow.cc b/rtgui/rtwindow.cc
index a543c383c..9163a1162 100644
--- a/rtgui/rtwindow.cc
+++ b/rtgui/rtwindow.cc
@@ -385,6 +385,13 @@ RTWindow::RTWindow ()
iccProfileCreator->set_tooltip_markup (M ("MAIN_BUTTON_ICCPROFCREATOR"));
iccProfileCreator->signal_clicked().connect ( sigc::mem_fun (*this, &RTWindow::showICCProfileCreator) );
+ Gtk::Button* helpBtnloc = Gtk::manage (new Gtk::Button ());
+ setExpandAlignProperties (helpBtnloc, false, false, Gtk::ALIGN_CENTER, Gtk::ALIGN_CENTER);
+ helpBtnloc->set_relief(Gtk::RELIEF_NONE);
+ helpBtnloc->set_image (*Gtk::manage (new RTImage ("questionmark.png")));
+ helpBtnloc->set_tooltip_markup (M ("LOCAL_HELP"));
+ helpBtnloc->signal_clicked().connect (sigc::mem_fun (*this, &RTWindow::showRawPedialoc));
+
Gtk::Button* helpBtn = Gtk::manage (new Gtk::Button ());
setExpandAlignProperties (helpBtn, false, false, Gtk::ALIGN_CENTER, Gtk::ALIGN_CENTER);
helpBtn->set_relief(Gtk::RELIEF_NONE);
@@ -420,6 +427,7 @@ RTWindow::RTWindow ()
actionGrid->set_orientation (Gtk::ORIENTATION_VERTICAL);
actionGrid->attach_next_to (prProgBar, Gtk::POS_BOTTOM, 1, 1);
actionGrid->attach_next_to (*iccProfileCreator, Gtk::POS_BOTTOM, 1, 1);
+ actionGrid->attach_next_to (*helpBtnloc, Gtk::POS_BOTTOM, 1, 1);
actionGrid->attach_next_to (*helpBtn, Gtk::POS_BOTTOM, 1, 1);
actionGrid->attach_next_to (*preferences, Gtk::POS_BOTTOM, 1, 1);
actionGrid->attach_next_to (*btn_fullscreen, Gtk::POS_BOTTOM, 1, 1);
@@ -429,6 +437,7 @@ RTWindow::RTWindow ()
actionGrid->set_orientation (Gtk::ORIENTATION_HORIZONTAL);
actionGrid->attach_next_to (prProgBar, Gtk::POS_RIGHT, 1, 1);
actionGrid->attach_next_to (*iccProfileCreator, Gtk::POS_RIGHT, 1, 1);
+ actionGrid->attach_next_to (*helpBtnloc, Gtk::POS_RIGHT, 1, 1);
actionGrid->attach_next_to (*helpBtn, Gtk::POS_RIGHT, 1, 1);
actionGrid->attach_next_to (*preferences, Gtk::POS_RIGHT, 1, 1);
actionGrid->attach_next_to (*btn_fullscreen, Gtk::POS_RIGHT, 1, 1);
@@ -927,6 +936,12 @@ void RTWindow::showRawPedia()
gtk_show_uri(nullptr, "https://rawpedia.rawtherapee.com/", GDK_CURRENT_TIME, &gerror);
}
+void RTWindow::showRawPedialoc()
+{
+ GError* gerror = nullptr;
+ gtk_show_uri(nullptr, "https://rawpedia.rawtherapee.com/Local_Adjustments/fr", GDK_CURRENT_TIME, &gerror);
+}
+
void RTWindow::showICCProfileCreator ()
{
ICCProfileCreator *iccpc = new ICCProfileCreator (this);
diff --git a/rtgui/rtwindow.h b/rtgui/rtwindow.h
index 2d4e390e8..948fddff5 100644
--- a/rtgui/rtwindow.h
+++ b/rtgui/rtwindow.h
@@ -91,6 +91,7 @@ public:
void on_mainNB_switch_page (Gtk::Widget* widget, guint page_num);
void showRawPedia();
+ void showRawPedialoc();
void showICCProfileCreator ();
void showPreferences ();
void on_realize () override;