From 951a161a0922dd440bef93879ecad60b45e0b416 Mon Sep 17 00:00:00 2001 From: Desmis Date: Sat, 28 Sep 2019 08:47:45 +0200 Subject: [PATCH] Change default settings --- rtdata/languages/default | 4 ++-- rtengine/ipretinex.cc | 10 ++++------ rtgui/locallab.cc | 12 ++++++++---- 3 files changed, 14 insertions(+), 12 deletions(-) diff --git a/rtdata/languages/default b/rtdata/languages/default index 2e51b255a..2011c7344 100644 --- a/rtdata/languages/default +++ b/rtdata/languages/default @@ -2146,7 +2146,7 @@ TP_LOCALLAB_EXPOSE;Exposure TP_LOCALLAB_EXPOSURE_TOOLTIP;In some cases (strong shadows ..) you can use the module "Shadows Highlights" TP_LOCALLAB_EXPCHROMA;Chroma compensation TP_LOCALLAB_GUIDFILTER;Guided filter radius -TP_LOCALLAB_GUIDFILTER_TOOLTIP;Adapt this values according to images - reduce if non misty images +TP_LOCALLAB_GUIDFILTER_TOOLTIP;Adapt this values according to images - can reduce or increase artifacts. TP_LOCALLAB_LOC_CONTRAST;Local contrast TP_LOCALLAB_LAPLACEXP;Laplacian threshold TP_LOCALLAB_BALANEXP;PDE balance @@ -2506,7 +2506,7 @@ TP_RETINEX_MEDIAN;Transmission median filter TP_RETINEX_METHOD;Method TP_RETINEX_METHOD_TOOLTIP;Low = Reinforce low light.\nUniform = Equalize action.\nHigh = Reinforce high light.\nHighlights = Remove magenta in highlights. TP_RETINEX_MLABEL;Restored data Min=%1 Max=%2 -TP_RETINEX_MLABEL_TOOLTIP;Should be near min=0 max=32768\nRestored image with no mixture. +TP_RETINEX_MLABEL_TOOLTIP;'Should be' near min=0 max=32768 but others values are possible\nRestored image with no mixture. TP_RETINEX_NEIGHBOR;Radius TP_RETINEX_NEUTRAL;Reset TP_RETINEX_NEUTRAL_TIP;Reset all sliders and curves to their default values. diff --git a/rtengine/ipretinex.cc b/rtengine/ipretinex.cc index d54316260..acdb35a26 100644 --- a/rtengine/ipretinex.cc +++ b/rtengine/ipretinex.cc @@ -1403,10 +1403,10 @@ void ImProcFunctions::MSRLocal(int sp, bool fftw, int lum, LabImage * bufreti, L } } - if (scal == 1) { + if (scal != 1) { float mintran = luminance[0][0]; float maxtran = mintran; - /* + #ifdef _OPENMP #pragma omp parallel for reduction(min:mintran) reduction(max:maxtran) schedule(dynamic,16) #endif @@ -1417,9 +1417,7 @@ void ImProcFunctions::MSRLocal(int sp, bool fftw, int lum, LabImage * bufreti, L maxtran = rtengine::max(luminance[ir][jr], maxtran); } } - */ - mintran = 0.f; - maxtran = 1.f; + float deltatran = maxtran - mintran; array2D ble(W_L, H_L); array2D guid(W_L, H_L); @@ -1433,7 +1431,7 @@ void ImProcFunctions::MSRLocal(int sp, bool fftw, int lum, LabImage * bufreti, L ble[i][j] = (luminance[i][j] + mintran) / deltatran; } - double epsilmax = 1e-3; + double epsilmax = 1e-2; double epsilmin = 1e-4; float radi = loc.spots.at(sp).softradiusret; diff --git a/rtgui/locallab.cc b/rtgui/locallab.cc index 9a0b9c05f..e004fed9f 100644 --- a/rtgui/locallab.cc +++ b/rtgui/locallab.cc @@ -270,7 +270,7 @@ Locallab::Locallab(): chrrt(Gtk::manage(new Adjuster(M("TP_LOCALLAB_CHRRT"), 0.0, 100.0, 0.1, 0.0))), neigh(Gtk::manage(new Adjuster(M("TP_LOCALLAB_NEIGH"), MINNEIGH, MAXNEIGH, 0.5, 50., nullptr, nullptr, &retiSlider2neigh, &retiNeigh2Slider))), vart(Gtk::manage(new Adjuster(M("TP_LOCALLAB_VART"), 0.1, 500., 0.1, 150.))), - offs(Gtk::manage(new Adjuster(M("TP_LOCALLAB_OFFS"), -4000., 10000., 1., 0.))), + offs(Gtk::manage(new Adjuster(M("TP_LOCALLAB_OFFS"), -10000., 20000., 1., 0.))), dehaz(Gtk::manage(new Adjuster(M("TP_LOCALLAB_DEHAZ"), 0, 100, 1, 0))), depth(Gtk::manage(new Adjuster(M("TP_LOCALLAB_DEPTH"), 0, 100, 1, 25))), sensih(Gtk::manage(new Adjuster(M("TP_LOCALLAB_SENSIH"), 0, 100, 1, 30))), @@ -281,8 +281,8 @@ Locallab::Locallab(): gammaskreti(Gtk::manage(new Adjuster(M("TP_LOCALLAB_GAMMASKCOL"), 0.05, 5.0, 0.01, 1.))), slomaskreti(Gtk::manage(new Adjuster(M("TP_LOCALLAB_SLOMASKCOL"), 0.0, 15.0, 0.1, 0.))), scalereti(Gtk::manage(new Adjuster(M("TP_LOCALLAB_SCALERETI"), 1.0, 10.0, 1., 2.))), - darkness(Gtk::manage(new Adjuster(M("TP_LOCALLAB_DARKRETI"), 0.01, 4.0, 0.01, 2.0))), - lightnessreti(Gtk::manage(new Adjuster(M("TP_LOCALLAB_LIGHTRETI"), 0.01, 3.0, 0.01, 1.))), + darkness(Gtk::manage(new Adjuster(M("TP_LOCALLAB_DARKRETI"), 0.01, 6.0, 0.01, 2.0))), + lightnessreti(Gtk::manage(new Adjuster(M("TP_LOCALLAB_LIGHTRETI"), 0.01, 4.0, 0.01, 1.))), limd(Gtk::manage(new Adjuster(M("TP_LOCALLAB_THRESRETI"), 1.2, 100.0, 0.1, 8.))), // Sharpening sharcontrast(Gtk::manage(new Adjuster(M("TP_SHARPENING_CONTRAST"), 0, 200, 1, 20))), @@ -1526,7 +1526,7 @@ Locallab::Locallab(): retiBox->pack_start(*offs); retiBox->pack_start(*darkness); retiBox->pack_start(*lightnessreti); -// retiBox->pack_start(*softradiusret); + retiBox->pack_start(*softradiusret); retiBox->pack_start(*mMLabels); retiBox->pack_start(*transLabels); retiBox->pack_start(*transLabels2); @@ -6560,10 +6560,12 @@ void Locallab::adjusterChanged(Adjuster * a, double newval) if (scalereti->getValue() == 1) { LocalcurveEditorgainT->hide(); LocalcurveEditortransT->hide(); + softradiusret->hide(); retinexMethod->hide(); } else { LocalcurveEditorgainT->show(); LocalcurveEditortransT->show(); + softradiusret->show(); retinexMethod->show(); } @@ -7407,10 +7409,12 @@ void Locallab::updateLocallabGUI(const rtengine::procparams::ProcParams* pp, con if (pp->locallab.spots.at(index).scalereti == 1) { LocalcurveEditorgainT->hide(); LocalcurveEditortransT->hide(); + softradiusret->hide(); retinexMethod->hide(); } else { LocalcurveEditorgainT->show(); LocalcurveEditortransT->show(); + softradiusret->show(); retinexMethod->show(); }