Improve local denoise with low levels wavelet

This commit is contained in:
Desmis 2019-04-11 11:05:22 +02:00
parent e80617d39b
commit 79455f9c09
10 changed files with 94 additions and 17 deletions

View File

@ -827,7 +827,7 @@ HISTORY_MSG_577;Local - cbdl chroma
HISTORY_MSG_578;Local - cbdl threshold
HISTORY_MSG_579;Local - cbdl scope
HISTORY_MSG_580;Local - Denoise
HISTORY_MSG_581;Local - deNoise lum f
HISTORY_MSG_581;Local - deNoise lum f 1
HISTORY_MSG_582;Local - deNoise lum c
HISTORY_MSG_583;Local - deNoise lum detail
HISTORY_MSG_584;Local - deNoise Equalizer white-black
@ -906,6 +906,8 @@ HISTORY_MSG_658;Local - CBDL soft radius
HISTORY_MSG_659;L*a*b Spot transition-weakening
HISTORY_MSG_660;Local - cbdl clarity
HISTORY_MSG_661;Local - cbdl contrast residual
HISTORY_MSG_662;Local - deNoise lum f 0
HISTORY_MSG_663;Local - deNoise lum f 2
HISTORY_MSG_CLAMPOOG;Clip out-of-gamut colors
HISTORY_MSG_COLORTONING_LABGRID_VALUE;CT - Color correction
HISTORY_MSG_COLORTONING_LABREGION_AB;CT - Color correction
@ -2014,7 +2016,9 @@ TP_LOCALLAB_EXPOSURE_TOOLTIP;In some cases (strong shadows ..) you can use the m
TP_LOCALLAB_EXPCHROMA;Chroma compensation
TP_LOCALLAB_LOC_CONTRAST;Local contrast
TP_LOCALLAB_REFLABEL;Ref. (0..1) Chroma=%1 Luma=%2 Hue=%3
TP_LOCALLAB_NOISELUMFINE;Luminance fine (Wav)
TP_LOCALLAB_NOISELUMFINE;Luminance fine 1 (Wav)
TP_LOCALLAB_NOISELUMFINEZERO;Luminance fine 0 (Wav)
TP_LOCALLAB_NOISELUMFINETWO;Luminance fine 2 (Wav)
TP_LOCALLAB_NOISELUMCOARSE;Luminance coarse (Wav)
TP_LOCALLAB_NOISELUMDETAIL;Luminance detail (DCT)
TP_LOCALLAB_NOISELEQUAL;Equalizer white-black

View File

@ -221,6 +221,8 @@ struct local_params {
int showmaskSHmet;
int blurmet;
float noiself;
float noiself0;
float noiself2;
float noiseldetail;
int noiselequal;
float noisechrodetail;
@ -437,6 +439,8 @@ static void calcLocalParams(int sp, int oW, int oH, const LocallabParams& locall
}
float local_noiself = (float)locallab.spots.at(sp).noiselumf;
float local_noiself0 = (float)locallab.spots.at(sp).noiselumf0;
float local_noiself2 = (float)locallab.spots.at(sp).noiselumf2;
float local_noiselc = (float)locallab.spots.at(sp).noiselumc;
float local_noiseldetail = (float)locallab.spots.at(sp).noiselumdetail;
int local_noiselequal = locallab.spots.at(sp).noiselequal;
@ -622,6 +626,8 @@ static void calcLocalParams(int sp, int oW, int oH, const LocallabParams& locall
lp.thr = thre;
lp.stru = strucc;
lp.noiself = local_noiself;
lp.noiself0 = local_noiself0;
lp.noiself2 = local_noiself2;
lp.noiseldetail = local_noiseldetail;
lp.noiselequal = local_noiselequal;
lp.noisechrodetail = local_noisechrodetail;
@ -3440,7 +3446,7 @@ void ImProcFunctions::calc_ref(int sp, LabImage * original, LabImage * transform
deltasobelL = new LabImage(spotSi, spotSi);
bool isdenoise = false;
if ((lp.noiself > 0.f || lp.noiselc > 0.f || lp.noisecf > 0.f || lp.noisecc > 0.f) && lp.denoiena) {
if ((lp.noiself > 0.f || lp.noiself0 > 0.f || lp.noiself2 > 0.f || lp.noiselc > 0.f || lp.noisecf > 0.f || lp.noisecc > 0.f) && lp.denoiena) {
isdenoise = true;
}
@ -4068,7 +4074,7 @@ void ImProcFunctions::Lab_Local(int call, int sp, float** shbuffer, LabImage * o
bool execbdl = (lp.mulloc[0] != 1.f || lp.mulloc[1] != 1.f || lp.mulloc[2] != 1.f || lp.mulloc[3] != 1.f || lp.mulloc[4] != 1.f) ;//only if user want cbdl
bool execdenoi = noiscfactiv && ((lp.colorena && execcolor) || (lp.tonemapena && lp.strengt != 0.f) || (lp.cbdlena && execbdl) || (lp.sfena && lp.strng > 0.f) || (lp.lcena && lp.lcamount > 0.f) || (lp.sharpena && lp.shrad > 0.42) || (lp.retiena && lp.str > 0.f) || (lp.exposena && lp.expcomp != 0.f) || (lp.expvib && lp.past != 0.f));
if (((lp.noiself > 0.f || lp.noiselc > 0.f || lp.noisecf > 0.f || lp.noisecc > 0.f) && lp.denoiena) || execdenoi) { // sk == 1 ??
if (((lp.noiself > 0.f || lp.noiself0 > 0.f || lp.noiself2 > 0.f || lp.noiselc > 0.f || lp.noisecf > 0.f || lp.noisecc > 0.f) && lp.denoiena) || execdenoi) { // sk == 1 ??
StopWatch Stop1("locallab Denoise called");
MyMutex::MyLock lock(*fftwMutex);
@ -4141,9 +4147,9 @@ void ImProcFunctions::Lab_Local(int call, int sp, float** shbuffer, LabImage * o
if (levred == 7) {
edge = 2;
vari[0] = 8.f * SQR((lp.noiself / 125.0) * (1.0 + lp.noiself / 25.0));
vari[0] = 8.f * SQR((lp.noiself0 / 125.0) * (1.0 + lp.noiself0 / 25.0));
vari[1] = 8.f * SQR((lp.noiself / 125.0) * (1.0 + lp.noiself / 25.0));
vari[2] = 8.f * SQR((lp.noiselc / 125.0) * (1.0 + lp.noiselc / 25.0));
vari[2] = 8.f * SQR((lp.noiself2 / 125.0) * (1.0 + lp.noiself2 / 25.0));
vari[3] = 8.f * SQR((lp.noiselc / 125.0) * (1.0 + lp.noiselc / 25.0));
vari[4] = 8.f * SQR((lp.noiselc / 125.0) * (1.0 + lp.noiselc / 25.0));
@ -4151,14 +4157,14 @@ void ImProcFunctions::Lab_Local(int call, int sp, float** shbuffer, LabImage * o
vari[6] = 8.f * SQR((lp.noiselc / 125.0) * (1.0 + lp.noiselc / 25.0));
} else if (levred == 4) {
edge = 3;
vari[0] = 8.f * SQR((lp.noiself / 125.0) * (1.0 + lp.noiself / 25.0));
vari[0] = 8.f * SQR((lp.noiself0 / 125.0) * (1.0 + lp.noiself0 / 25.0));
vari[1] = 8.f * SQR((lp.noiself / 125.0) * (1.0 + lp.noiself / 25.0));
vari[2] = 8.f * SQR((lp.noiselc / 125.0) * (1.0 + lp.noiselc / 25.0));
vari[3] = 8.f * SQR((lp.noiselc / 125.0) * (1.0 + lp.noiselc / 25.0));
}
if ((lp.noiself >= 0.1f || lp.noiselc >= 0.1f)) {
if ((lp.noiself >= 0.1f || lp.noiself0 >= 0.1f || lp.noiself2 >= 0.1f || lp.noiselc >= 0.1f)) {
float kr3 = 0.f;
float kr4 = 0.f;
float kr5 = 0.f;
@ -4506,7 +4512,7 @@ void ImProcFunctions::Lab_Local(int call, int sp, float** shbuffer, LabImage * o
}
if (!Ldecomp.memoryAllocationFailed) {
if ((lp.noiself >= 0.1f || lp.noiselc >= 0.1f) && levred == 7) {
if ((lp.noiself >= 0.1f || lp.noiself0 >= 0.1f || lp.noiself2 >= 0.1f || lp.noiselc >= 0.1f) && levred == 7) {
fftw_denoise(GW, GH, max_numblox_W, min_numblox_W, tmp1.L, Lin, numThreads, lp, 0);
}
}
@ -4638,9 +4644,9 @@ void ImProcFunctions::Lab_Local(int call, int sp, float** shbuffer, LabImage * o
if (levred == 7) {
edge = 2;
vari[0] = 8.f * SQR((lp.noiself / 125.0) * (1.0 + lp.noiself / 25.0));
vari[0] = 8.f * SQR((lp.noiself0 / 125.0) * (1.0 + lp.noiself0 / 25.0));
vari[1] = 8.f * SQR((lp.noiself / 125.0) * (1.0 + lp.noiself / 25.0));
vari[2] = 8.f * SQR((lp.noiselc / 125.0) * (1.0 + lp.noiselc / 25.0));
vari[2] = 8.f * SQR((lp.noiself2 / 125.0) * (1.0 + lp.noiself2 / 25.0));
vari[3] = 8.f * SQR((lp.noiselc / 125.0) * (1.0 + lp.noiselc / 25.0));
vari[4] = 8.f * SQR((lp.noiselc / 125.0) * (1.0 + lp.noiselc / 25.0));
@ -4648,7 +4654,7 @@ void ImProcFunctions::Lab_Local(int call, int sp, float** shbuffer, LabImage * o
vari[6] = 8.f * SQR((lp.noiselc / 125.0) * (1.0 + lp.noiselc / 25.0));
} else if (levred == 4) {
edge = 3;
vari[0] = 8.f * SQR((lp.noiself / 125.0) * (1.0 + lp.noiself / 25.0));
vari[0] = 8.f * SQR((lp.noiself0 / 125.0) * (1.0 + lp.noiself0 / 25.0));
vari[1] = 8.f * SQR((lp.noiself / 125.0) * (1.0 + lp.noiself / 25.0));
vari[2] = 8.f * SQR((lp.noiselc / 125.0) * (1.0 + lp.noiselc / 25.0));
vari[3] = 8.f * SQR((lp.noiselc / 125.0) * (1.0 + lp.noiselc / 25.0));
@ -4656,7 +4662,7 @@ void ImProcFunctions::Lab_Local(int call, int sp, float** shbuffer, LabImage * o
}
if ((lp.noiself >= 0.1f || lp.noiselc >= 0.1f)) {
if ((lp.noiself >= 0.1f || lp.noiself0 >= 0.1f || lp.noiself2 >= 0.1f || lp.noiselc >= 0.1f)) {
float kr3 = 0.f;
float kr4 = 0.f;
float kr5 = 0.f;
@ -5008,7 +5014,7 @@ void ImProcFunctions::Lab_Local(int call, int sp, float** shbuffer, LabImage * o
if (!Ldecomp.memoryAllocationFailed) {
if ((lp.noiself >= 0.1f || lp.noiselc >= 0.1f) && levred == 7) {
if ((lp.noiself >= 0.1f || lp.noiself0 >= 0.1f || lp.noiself2 >= 0.1f || lp.noiselc >= 0.1f) && levred == 7) {
fftw_denoise(bfw, bfh, max_numblox_W, min_numblox_W, bufwv.L, Lin, numThreads, lp, 0);
}
}

View File

@ -688,6 +688,8 @@ enum ProcEventCode {
EvLocallabSpotTransitweak = 658,
EvLocallabclarityml = 659,
EvLocallabcontresid = 660,
Evlocallabnoiselumf0 = 661,
Evlocallabnoiselumf2 = 662,
NUMOFEVENTS
};

View File

@ -2503,6 +2503,8 @@ LocallabParams::LocallabSpot::LocallabSpot() :
// Denoise
expdenoi(false),
noiselumf(0),
noiselumf0(0),
noiselumf2(0),
noiselumc(0),
noiselumdetail(0),
noiselequal(7),
@ -2695,6 +2697,8 @@ bool LocallabParams::LocallabSpot::operator ==(const LocallabSpot& other) const
// Denoise
&& expdenoi == other.expdenoi
&& noiselumf == other.noiselumf
&& noiselumf0 == other.noiselumf0
&& noiselumf2 == other.noiselumf2
&& noiselumc == other.noiselumc
&& noiselumdetail == other.noiselumdetail
&& noiselequal == other.noiselequal
@ -3829,6 +3833,8 @@ int ProcParams::save(const Glib::ustring& fname, const Glib::ustring& fname2, bo
// Denoise
saveToKeyfile(!pedited || pedited->locallab.spots.at(i).expdenoi, "Locallab", "Expdenoi_" + std::to_string(i), spot.expdenoi, keyFile);
saveToKeyfile(!pedited || pedited->locallab.spots.at(i).noiselumf, "Locallab", "noiselumf_" + std::to_string(i), spot.noiselumf, keyFile);
saveToKeyfile(!pedited || pedited->locallab.spots.at(i).noiselumf0, "Locallab", "noiselumf0_" + std::to_string(i), spot.noiselumf0, keyFile);
saveToKeyfile(!pedited || pedited->locallab.spots.at(i).noiselumf2, "Locallab", "noiselumf2_" + std::to_string(i), spot.noiselumf2, keyFile);
saveToKeyfile(!pedited || pedited->locallab.spots.at(i).noiselumc, "Locallab", "noiselumc_" + std::to_string(i), spot.noiselumc, keyFile);
saveToKeyfile(!pedited || pedited->locallab.spots.at(i).noiselumdetail, "Locallab", "noiselumdetail_" + std::to_string(i), spot.noiselumdetail, keyFile);
saveToKeyfile(!pedited || pedited->locallab.spots.at(i).noiselequal, "Locallab", "noiselequal_" + std::to_string(i), spot.noiselequal, keyFile);
@ -5109,6 +5115,8 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
// Denoise
assignFromKeyfile(keyFile, "Locallab", "Expdenoi_" + std::to_string(i), pedited, spot.expdenoi, spotEdited.expdenoi);
assignFromKeyfile(keyFile, "Locallab", "noiselumf_" + std::to_string(i), pedited, spot.noiselumf, spotEdited.noiselumf);
assignFromKeyfile(keyFile, "Locallab", "noiselumf0_" + std::to_string(i), pedited, spot.noiselumf0, spotEdited.noiselumf0);
assignFromKeyfile(keyFile, "Locallab", "noiselumf2_" + std::to_string(i), pedited, spot.noiselumf2, spotEdited.noiselumf2);
assignFromKeyfile(keyFile, "Locallab", "noiselumc_" + std::to_string(i), pedited, spot.noiselumc, spotEdited.noiselumc);
assignFromKeyfile(keyFile, "Locallab", "noiselumdetail_" + std::to_string(i), pedited, spot.noiselumdetail, spotEdited.noiselumdetail);
assignFromKeyfile(keyFile, "Locallab", "noiselequal_" + std::to_string(i), pedited, spot.noiselequal, spotEdited.noiselequal);

View File

@ -1104,6 +1104,8 @@ struct LocallabParams {
// Denoise
bool expdenoi;
int noiselumf;
int noiselumf0;
int noiselumf2;
int noiselumc;
int noiselumdetail;
int noiselequal;

View File

@ -687,7 +687,9 @@ int refreshmap[rtengine::NUMOFEVENTS] = {
LUMINANCECURVE, //EvLocallabsoftradiuscb
LUMINANCECURVE, // EvLocallabSpotTransitweak
LUMINANCECURVE, // EvLocallabclarityml
LUMINANCECURVE // EvLocallabcontresid
LUMINANCECURVE, // EvLocallabcontresid
LUMINANCECURVE, //Evlocallabnoiselumf0
LUMINANCECURVE //Evlocallabnoiselumf2
};

View File

@ -168,6 +168,8 @@ Locallab::Locallab():
softradiuscb(Gtk::manage(new Adjuster(M("TP_LOCALLAB_SOFTRADIUSCOL"), 0.0, 100.0, 0.1, 0.))),
// Denoise
noiselumf(Gtk::manage(new Adjuster(M("TP_LOCALLAB_NOISELUMFINE"), MINCHRO, MAXCHRO, 1, 0))),
noiselumf0(Gtk::manage(new Adjuster(M("TP_LOCALLAB_NOISELUMFINEZERO"), MINCHRO, MAXCHRO, 1, 0))),
noiselumf2(Gtk::manage(new Adjuster(M("TP_LOCALLAB_NOISELUMFINETWO"), MINCHRO, MAXCHRO, 1, 0))),
noiselumc(Gtk::manage(new Adjuster(M("TP_LOCALLAB_NOISELUMCOARSE"), MINCHRO, MAXCHROCC, 1, 0))),
noiselumdetail(Gtk::manage(new Adjuster(M("TP_LOCALLAB_NOISELUMDETAIL"), 0, 100, 1, 0))),
noiselequal(Gtk::manage(new Adjuster(M("TP_LOCALLAB_NOISELEQUAL"), -2, 10, 1, 7, Gtk::manage(new RTImage("circle-white-small.png")), Gtk::manage(new RTImage("circle-black-small.png"))))),
@ -972,6 +974,8 @@ Locallab::Locallab():
enabledenoiConn = expdenoi->signal_enabled_toggled().connect(sigc::bind(sigc::mem_fun(this, &Locallab::enableToggled), expdenoi));
noiselumf->setAdjusterListener(this);
noiselumf0->setAdjusterListener(this);
noiselumf2->setAdjusterListener(this);
if(showtooltip) noiselumc->set_tooltip_text(M("TP_LOCALLAB_NOISECHROC_TOOLTIP"));
noiselumc->setAdjusterListener(this);
@ -996,7 +1000,9 @@ Locallab::Locallab():
ToolParamBlock* const denoisBox = Gtk::manage(new ToolParamBlock());
Gtk::Frame* const wavFrame = Gtk::manage(new Gtk::Frame());
ToolParamBlock* const wavBox = Gtk::manage(new ToolParamBlock());
wavBox->pack_start(*noiselumf0);
wavBox->pack_start(*noiselumf);
wavBox->pack_start(*noiselumf2);
wavBox->pack_start(*noiselumc);
wavBox->pack_start(*noiselumdetail);
wavBox->pack_start(*noiselequal);
@ -1867,6 +1873,8 @@ void Locallab::write(ProcParams* pp, ParamsEdited* pedited)
// Denoise
pp->locallab.spots.at(pp->locallab.selspot).expdenoi = expdenoi->getEnabled();
pp->locallab.spots.at(pp->locallab.selspot).noiselumf = noiselumf->getIntValue();
pp->locallab.spots.at(pp->locallab.selspot).noiselumf0 = noiselumf0->getIntValue();
pp->locallab.spots.at(pp->locallab.selspot).noiselumf2 = noiselumf2->getIntValue();
pp->locallab.spots.at(pp->locallab.selspot).noiselumc = noiselumc->getIntValue();
pp->locallab.spots.at(pp->locallab.selspot).noiselumdetail = noiselumdetail->getIntValue();
pp->locallab.spots.at(pp->locallab.selspot).noiselequal = noiselequal->getIntValue();
@ -2049,6 +2057,8 @@ void Locallab::write(ProcParams* pp, ParamsEdited* pedited)
// Denoise
pe->locallab.spots.at(pp->locallab.selspot).expdenoi = pe->locallab.spots.at(pp->locallab.selspot).expdenoi || !expdenoi->get_inconsistent();
pe->locallab.spots.at(pp->locallab.selspot).noiselumf = pe->locallab.spots.at(pp->locallab.selspot).noiselumf || noiselumf->getEditedState();
pe->locallab.spots.at(pp->locallab.selspot).noiselumf0 = pe->locallab.spots.at(pp->locallab.selspot).noiselumf0 || noiselumf0->getEditedState();
pe->locallab.spots.at(pp->locallab.selspot).noiselumf2 = pe->locallab.spots.at(pp->locallab.selspot).noiselumf2 || noiselumf2->getEditedState();
pe->locallab.spots.at(pp->locallab.selspot).noiselumc = pe->locallab.spots.at(pp->locallab.selspot).noiselumc || noiselumc->getEditedState();
pe->locallab.spots.at(pp->locallab.selspot).noiselumdetail = pe->locallab.spots.at(pp->locallab.selspot).noiselumdetail || noiselumdetail->getEditedState();
pe->locallab.spots.at(pp->locallab.selspot).noiselequal = pe->locallab.spots.at(pp->locallab.selspot).noiselequal || noiselequal->getEditedState();
@ -2233,6 +2243,8 @@ void Locallab::write(ProcParams* pp, ParamsEdited* pedited)
// Denoise
pedited->locallab.spots.at(pp->locallab.selspot).expdenoi = pedited->locallab.spots.at(pp->locallab.selspot).expdenoi || !expdenoi->get_inconsistent();
pedited->locallab.spots.at(pp->locallab.selspot).noiselumf = pedited->locallab.spots.at(pp->locallab.selspot).noiselumf || noiselumf->getEditedState();
pedited->locallab.spots.at(pp->locallab.selspot).noiselumf0 = pedited->locallab.spots.at(pp->locallab.selspot).noiselumf0 || noiselumf0->getEditedState();
pedited->locallab.spots.at(pp->locallab.selspot).noiselumf2 = pedited->locallab.spots.at(pp->locallab.selspot).noiselumf2 || noiselumf2->getEditedState();
pedited->locallab.spots.at(pp->locallab.selspot).noiselumc = pedited->locallab.spots.at(pp->locallab.selspot).noiselumc || noiselumc->getEditedState();
pedited->locallab.spots.at(pp->locallab.selspot).noiselumdetail = pedited->locallab.spots.at(pp->locallab.selspot).noiselumdetail || noiselumdetail->getEditedState();
pedited->locallab.spots.at(pp->locallab.selspot).noiselequal = pedited->locallab.spots.at(pp->locallab.selspot).noiselequal || noiselequal->getEditedState();
@ -3097,6 +3109,8 @@ void Locallab::setDefaults(const ProcParams * defParams, const ParamsEdited * pe
softradiuscb->setDefault(defSpot->softradiuscb);
// Denoise
noiselumf->setDefault((double)defSpot->noiselumf);
noiselumf0->setDefault((double)defSpot->noiselumf0);
noiselumf2->setDefault((double)defSpot->noiselumf2);
noiselumc->setDefault((double)defSpot->noiselumc);
noiselumdetail->setDefault((double)defSpot->noiselumdetail);
noiselequal->setDefault((double)defSpot->noiselequal);
@ -3208,6 +3222,8 @@ void Locallab::setDefaults(const ProcParams * defParams, const ParamsEdited * pe
softradiuscb->setDefaultEditedState(Irrelevant);
// Denoise
noiselumf->setDefaultEditedState(Irrelevant);
noiselumf0->setDefaultEditedState(Irrelevant);
noiselumf2->setDefaultEditedState(Irrelevant);
noiselumc->setDefaultEditedState(Irrelevant);
noiselumdetail->setDefaultEditedState(Irrelevant);
noiselequal->setDefaultEditedState(Irrelevant);
@ -3323,6 +3339,8 @@ void Locallab::setDefaults(const ProcParams * defParams, const ParamsEdited * pe
softradiuscb->setDefaultEditedState(defSpotState->softradiuscb ? Edited : UnEdited);
// Denoise
noiselumf->setDefaultEditedState(defSpotState->noiselumf ? Edited : UnEdited);
noiselumf0->setDefaultEditedState(defSpotState->noiselumf0 ? Edited : UnEdited);
noiselumf2->setDefaultEditedState(defSpotState->noiselumf2 ? Edited : UnEdited);
noiselumc->setDefaultEditedState(defSpotState->noiselumc ? Edited : UnEdited);
noiselumdetail->setDefaultEditedState(defSpotState->noiselumdetail ? Edited : UnEdited);
noiselequal->setDefaultEditedState(defSpotState->noiselequal ? Edited : UnEdited);
@ -3930,6 +3948,18 @@ void Locallab::adjusterChanged(Adjuster * a, double newval)
}
}
if (a == noiselumf0) {
if (listener) {
listener->panelChanged(Evlocallabnoiselumf0, noiselumf0->getTextValue());
}
}
if (a == noiselumf2) {
if (listener) {
listener->panelChanged(Evlocallabnoiselumf2, noiselumf2->getTextValue());
}
}
if (a == noiselumc) {
if (listener) {
listener->panelChanged(Evlocallabnoiselumc, noiselumc->getTextValue());
@ -4114,7 +4144,8 @@ void Locallab::setBatchMode(bool batchMode)
noiselumc->showEditedCB();
noiselumdetail->showEditedCB();
noiselequal->showEditedCB();
noiselumf->showEditedCB();
noiselumf0->showEditedCB();
noiselumf2->showEditedCB();
noisechroc->showEditedCB();
noisechrodetail->showEditedCB();
adjblur->showEditedCB();
@ -4553,6 +4584,8 @@ void Locallab::updateLocallabGUI(const rtengine::procparams::ProcParams* pp, con
// Denoise
expdenoi->setEnabled(pp->locallab.spots.at(index).expdenoi);
noiselumf->setValue(pp->locallab.spots.at(index).noiselumf);
noiselumf0->setValue(pp->locallab.spots.at(index).noiselumf0);
noiselumf2->setValue(pp->locallab.spots.at(index).noiselumf2);
noiselumc->setValue(pp->locallab.spots.at(index).noiselumc);
noiselumdetail->setValue(pp->locallab.spots.at(index).noiselumdetail);
noiselequal->setValue(pp->locallab.spots.at(index).noiselequal);
@ -4772,6 +4805,8 @@ void Locallab::updateLocallabGUI(const rtengine::procparams::ProcParams* pp, con
// Denoise
expdenoi->set_inconsistent(!spotState->expdenoi);
noiselumf->setEditedState(spotState->noiselumf ? Edited : UnEdited);
noiselumf0->setEditedState(spotState->noiselumf0 ? Edited : UnEdited);
noiselumf2->setEditedState(spotState->noiselumf2 ? Edited : UnEdited);
noiselumc->setEditedState(spotState->noiselumc ? Edited : UnEdited);
noiselumdetail->setEditedState(spotState->noiselumdetail ? Edited : UnEdited);
noiselequal->setEditedState(spotState->noiselequal ? Edited : UnEdited);

View File

@ -188,6 +188,8 @@ private:
Adjuster* const softradiuscb;
// Denoise
Adjuster* const noiselumf;
Adjuster* const noiselumf0;
Adjuster* const noiselumf2;
Adjuster* const noiselumc;
Adjuster* const noiselumdetail;
Adjuster* const noiselequal;

View File

@ -1097,6 +1097,8 @@ void ParamsEdited::initFrom(const std::vector<rtengine::procparams::ProcParams>&
// Denoise
locallab.spots.at(j).expdenoi = locallab.spots.at(j).expdenoi && pSpot.expdenoi == otherSpot.expdenoi;
locallab.spots.at(j).noiselumf = locallab.spots.at(j).noiselumf && pSpot.noiselumf == otherSpot.noiselumf;
locallab.spots.at(j).noiselumf0 = locallab.spots.at(j).noiselumf0 && pSpot.noiselumf0 == otherSpot.noiselumf0;
locallab.spots.at(j).noiselumf2 = locallab.spots.at(j).noiselumf2 && pSpot.noiselumf2 == otherSpot.noiselumf2;
locallab.spots.at(j).noiselumc = locallab.spots.at(j).noiselumc && pSpot.noiselumc == otherSpot.noiselumc;
locallab.spots.at(j).noiselumdetail = locallab.spots.at(j).noiselumdetail && pSpot.noiselumdetail == otherSpot.noiselumdetail;
locallab.spots.at(j).noiselequal = locallab.spots.at(j).noiselequal && pSpot.noiselequal == otherSpot.noiselequal;
@ -3158,6 +3160,14 @@ void ParamsEdited::combine(rtengine::procparams::ProcParams& toEdit, const rteng
toEdit.locallab.spots.at(i).noiselumf = mods.locallab.spots.at(i).noiselumf;
}
if (locallab.spots.at(i).noiselumf0) {
toEdit.locallab.spots.at(i).noiselumf0 = mods.locallab.spots.at(i).noiselumf0;
}
if (locallab.spots.at(i).noiselumf2) {
toEdit.locallab.spots.at(i).noiselumf2 = mods.locallab.spots.at(i).noiselumf2;
}
if (locallab.spots.at(i).noiselumc) {
toEdit.locallab.spots.at(i).noiselumc = mods.locallab.spots.at(i).noiselumc;
}
@ -4301,6 +4311,8 @@ LocallabParamsEdited::LocallabSpotEdited::LocallabSpotEdited(bool v) :
// Denoise
expdenoi(v),
noiselumf(v),
noiselumf0(v),
noiselumf2(v),
noiselumc(v),
noiselumdetail(v),
noiselequal(v),
@ -4485,6 +4497,8 @@ void LocallabParamsEdited::LocallabSpotEdited::set(bool v)
// Denoise
expdenoi = v;
noiselumf = v;
noiselumf0 = v;
noiselumf2 = v;
noiselumc = v;
noiselumdetail = v;
noiselequal = v;

View File

@ -520,6 +520,8 @@ public:
// Denoise
bool expdenoi;
bool noiselumf;
bool noiselumf0;
bool noiselumf2;
bool noiselumc;
bool noiselumdetail;
bool noiselequal;