save provisory GUI work
This commit is contained in:
parent
81638ffb00
commit
f4ad061cb9
@ -895,6 +895,11 @@ enum ProcEventCode {
|
||||
Evlocallabfatres = 866,
|
||||
EvLocallabSpotbalanh = 867,
|
||||
EvlocallabwavCurveden = 868,
|
||||
EvlocallabHHmasklcshape = 869,
|
||||
EvlocallabCCmasklcshape = 870,
|
||||
EvlocallabLLmasklcshape = 871,
|
||||
EvLocallabEnalcMask = 872,
|
||||
EvlocallabshowmasklcMethod = 873,
|
||||
NUMOFEVENTS
|
||||
};
|
||||
|
||||
|
@ -2743,6 +2743,11 @@ LocallabParams::LocallabSpot::LocallabSpot() :
|
||||
loclevwavcurve{(double)FCT_MinMaxCPoints, 0.0, 0.0, 0.0, 0.35, 0.5, 0., 0.35, 0.35, 1.0, 0.0, 0.35, 0.35},
|
||||
locconwavcurve{(double)FCT_MinMaxCPoints, 0.0, 0.5, 0.35, 0.35, 1., 0.5, 0.35, 0.35},
|
||||
loccompwavcurve{(double)FCT_MinMaxCPoints, 0.0, 0.0, 0.0, 0.35, 0.5, 0., 0.35, 0.35, 1.0, 0.0, 0.35, 0.35},
|
||||
CCmasklccurve{(double)FCT_MinMaxCPoints, 0.0, 1.0, 0.35, 0.35, 0.50, 1.0, 0.35, 0.35, 1.0, 1.0, 0.35, 0.35 },
|
||||
LLmasklccurve{(double)FCT_MinMaxCPoints, 0.0, 1.0, 0.35, 0.35, 0.50, 1.0, 0.35, 0.35, 1.0, 1.0, 0.35, 0.35},
|
||||
HHmasklccurve{(double)FCT_MinMaxCPoints, 0.0, 1.0, 0.35, 0.35, 0.50, 1.0, 0.35, 0.35, 1.0, 1.0, 0.35, 0.35},
|
||||
enalcMask(false),
|
||||
|
||||
// Contrast by detail levels
|
||||
expcbdl(false),
|
||||
mult{1.0, 1.0, 1.0, 1.0, 1.0, 1.0},
|
||||
@ -3139,6 +3144,10 @@ bool LocallabParams::LocallabSpot::operator ==(const LocallabSpot& other) const
|
||||
&& loclevwavcurve == other.loclevwavcurve
|
||||
&& locconwavcurve == other.locconwavcurve
|
||||
&& loccompwavcurve == other.loccompwavcurve
|
||||
&& CCmasklccurve == other.CCmasklccurve
|
||||
&& LLmasklccurve == other.LLmasklccurve
|
||||
&& HHmasklccurve == other.HHmasklccurve
|
||||
&& enalcMask == other.enalcMask
|
||||
// Constrast by detail levels
|
||||
&& expcbdl == other.expcbdl
|
||||
&& [this, &other]()->bool {
|
||||
@ -4515,6 +4524,12 @@ int ProcParams::save(const Glib::ustring& fname, const Glib::ustring& fname2, bo
|
||||
saveToKeyfile(!pedited || pedited->locallab.spots.at(i).locconwavcurve, "Locallab", "LocconwavCurve_" + std::to_string(i), spot.locconwavcurve, keyFile);
|
||||
saveToKeyfile(!pedited || pedited->locallab.spots.at(i).loccompwavcurve, "Locallab", "LoccompwavCurve_" + std::to_string(i), spot.loccompwavcurve, keyFile);
|
||||
saveToKeyfile(!pedited || pedited->locallab.spots.at(i).csthreshold, "Locallab", "CSThreshold_" + std::to_string(i), spot.csthreshold.toVector(), keyFile);
|
||||
|
||||
saveToKeyfile(!pedited || pedited->locallab.spots.at(i).CCmasklccurve, "Locallab", "CCmasklcCurve_" + std::to_string(i), spot.CCmasklccurve, keyFile);
|
||||
saveToKeyfile(!pedited || pedited->locallab.spots.at(i).LLmasklccurve, "Locallab", "LLmasklcCurve_" + std::to_string(i), spot.LLmasklccurve, keyFile);
|
||||
saveToKeyfile(!pedited || pedited->locallab.spots.at(i).HHmasklccurve, "Locallab", "HHmasklcCurve_" + std::to_string(i), spot.HHmasklccurve, keyFile);
|
||||
saveToKeyfile(!pedited || pedited->locallab.spots.at(i).enalcMask, "Locallab", "EnalcMask_" + std::to_string(i), spot.enalcMask, keyFile);
|
||||
|
||||
// Contrast by detail levels
|
||||
saveToKeyfile(!pedited || pedited->locallab.spots.at(i).expcbdl, "Locallab", "Expcbdl_" + std::to_string(i), spot.expcbdl, keyFile);
|
||||
|
||||
@ -6039,6 +6054,12 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
|
||||
assignFromKeyfile(keyFile, "Locallab", "LoclevwavCurve_" + std::to_string(i), pedited, spot.loclevwavcurve, spotEdited.loclevwavcurve);
|
||||
assignFromKeyfile(keyFile, "Locallab", "LocconwavCurve_" + std::to_string(i), pedited, spot.locconwavcurve, spotEdited.locconwavcurve);
|
||||
assignFromKeyfile(keyFile, "Locallab", "LoccompwavCurve_" + std::to_string(i), pedited, spot.loccompwavcurve, spotEdited.loccompwavcurve);
|
||||
|
||||
assignFromKeyfile(keyFile, "Locallab", "CCmasklcCurve_" + std::to_string(i), pedited, spot.CCmasklccurve, spotEdited.CCmasklccurve);
|
||||
assignFromKeyfile(keyFile, "Locallab", "LLmasklcCurve_" + std::to_string(i), pedited, spot.LLmasklccurve, spotEdited.LLmasklccurve);
|
||||
assignFromKeyfile(keyFile, "Locallab", "HHmasklcCurve_" + std::to_string(i), pedited, spot.HHmasklccurve, spotEdited.HHmasklccurve);
|
||||
assignFromKeyfile(keyFile, "Locallab", "EnalcMask_" + std::to_string(i), pedited, spot.enalcMask, spotEdited.enalcMask);
|
||||
|
||||
if (keyFile.has_key("Locallab", "CSThreshold_" + std::to_string(i))) {
|
||||
|
||||
const std::vector<int> thresh = keyFile.get_integer_list("Locallab", "CSThreshold_" + std::to_string(i));
|
||||
|
@ -1286,6 +1286,10 @@ struct LocallabParams {
|
||||
std::vector<double> loclevwavcurve;
|
||||
std::vector<double> locconwavcurve;
|
||||
std::vector<double> loccompwavcurve;
|
||||
std::vector<double> CCmasklccurve;
|
||||
std::vector<double> LLmasklccurve;
|
||||
std::vector<double> HHmasklccurve;
|
||||
bool enalcMask;
|
||||
|
||||
// Contrast by detail levels
|
||||
bool expcbdl;
|
||||
|
@ -898,7 +898,13 @@ int refreshmap[rtengine::NUMOFEVENTS] = {
|
||||
LUMINANCECURVE, //EvlocallabwavCurvecomp
|
||||
LUMINANCECURVE, //Evlocallabfatres
|
||||
LUMINANCECURVE, //EvLocallabSpotbalanh
|
||||
LUMINANCECURVE // EvlocallabwavCurveden
|
||||
LUMINANCECURVE, // EvlocallabwavCurveden
|
||||
LUMINANCECURVE, //EvlocallabHHmasklcshape
|
||||
LUMINANCECURVE, //EvlocallabCCmasklcshape
|
||||
LUMINANCECURVE, //EvlocallabLLmasklcshape
|
||||
LUMINANCECURVE, //EvlocallabEnalcMask
|
||||
LUMINANCECURVE //EvlocallabshowmasklcMethod
|
||||
|
||||
};
|
||||
|
||||
namespace rtengine
|
||||
|
@ -238,6 +238,7 @@ Locallab::Locallab():
|
||||
expcurvcol(Gtk::manage(new MyExpander(false, M("TP_LOCALLAB_EXPCURV")))),
|
||||
expmaskexp(Gtk::manage(new MyExpander(false, M("TP_LOCALLAB_SHOWE")))),
|
||||
expmasksh(Gtk::manage(new MyExpander(false, M("TP_LOCALLAB_SHOWS")))),
|
||||
expmasklc(Gtk::manage(new MyExpander(false, M("TP_LOCALLAB_SHOWCB")))),
|
||||
expmaskcb(Gtk::manage(new MyExpander(false, M("TP_LOCALLAB_SHOWCB")))),
|
||||
expmaskreti(Gtk::manage(new MyExpander(false, M("TP_LOCALLAB_SHOWR")))),
|
||||
expmasktm(Gtk::manage(new MyExpander(false, M("TP_LOCALLAB_SHOWT")))),
|
||||
@ -355,6 +356,11 @@ Locallab::Locallab():
|
||||
LocalcurveEditorwavcomp(new CurveEditorGroup(options.lastlocalCurvesDir, M("TP_LOCALLAB_WAVCOMP"))),
|
||||
wavshapecomp(static_cast<FlatCurveEditor*>(LocalcurveEditorwavcomp->addCurve(CT_Flat, "", nullptr, false, false))),
|
||||
|
||||
masklcCurveEditorG(new CurveEditorGroup(options.lastlocalCurvesDir, M("TP_LOCALLAB_MASK"))),
|
||||
CCmasklcshape(static_cast<FlatCurveEditor*>(masklcCurveEditorG->addCurve(CT_Flat, "C(C)", nullptr, false, false))),
|
||||
LLmasklcshape(static_cast<FlatCurveEditor*>(masklcCurveEditorG->addCurve(CT_Flat, "L(L)", nullptr, false, false))),
|
||||
HHmasklcshape(static_cast<FlatCurveEditor *>(masklcCurveEditorG->addCurve(CT_Flat, "LC(H)", nullptr, false, true))),
|
||||
|
||||
//CBDL
|
||||
maskcbCurveEditorG(new CurveEditorGroup(options.lastlocalCurvesDir, M("TP_LOCALLAB_MASK"))),
|
||||
mask2cbCurveEditorG(new CurveEditorGroup(options.lastlocalCurvesDir, M("TP_LOCALLAB_MASK2"))),
|
||||
@ -670,6 +676,7 @@ inverssha(Gtk::manage(new Gtk::CheckButton(M("TP_LOCALLAB_INVERS")))),
|
||||
fftwlc(Gtk::manage(new Gtk::CheckButton(M("TP_LOCALLAB_FFTW")))),
|
||||
blurlc(Gtk::manage(new Gtk::CheckButton(M("TP_LOCALLAB_BLURLC")))),
|
||||
origlc(Gtk::manage(new Gtk::CheckButton(M("TP_LOCALLAB_ORIGLC")))),
|
||||
enalcMask(Gtk::manage(new Gtk::CheckButton(M("TP_LOCALLAB_ENABLE_MASK")))),
|
||||
//CBDL
|
||||
enacbMask(Gtk::manage(new Gtk::CheckButton(M("TP_LOCALLAB_ENABLE_MASK")))),
|
||||
//encoding log
|
||||
@ -715,6 +722,7 @@ showmaskretiMethod(Gtk::manage(new MyComboBoxText())),
|
||||
//Local contrast
|
||||
localcontMethod(Gtk::manage(new MyComboBoxText())),
|
||||
csThreshold(Gtk::manage(new ThresholdAdjuster(M("TP_LOCALLAB_CSTHRESHOLD"), 0, 9, 0, 0, 6, 6, 0, false))),
|
||||
showmasklcMethod(Gtk::manage(new MyComboBoxText())),
|
||||
//CBDL
|
||||
showmaskcbMethod(Gtk::manage(new MyComboBoxText())),
|
||||
|
||||
@ -2790,6 +2798,15 @@ pe(nullptr)
|
||||
if (showtooltip) {
|
||||
fftwlc->set_tooltip_text(M("TP_LOCALLAB_LC_FFTW_TOOLTIP"));
|
||||
}
|
||||
|
||||
setExpandAlignProperties(expmasklc, true, false, Gtk::ALIGN_FILL, Gtk::ALIGN_START);
|
||||
expmasklc->signal_button_release_event().connect_notify(sigc::bind(sigc::mem_fun(this, &Locallab::foldAllButMe), expmasklc));
|
||||
expmasklc->setLevel(2);
|
||||
|
||||
if (showtooltip) {
|
||||
expmasklc->set_tooltip_markup(M("TP_LOCALLAB_MASK_TOOLTIP"));
|
||||
}
|
||||
|
||||
blurlcConn = blurlc->signal_toggled().connect(sigc::mem_fun(*this, &Locallab::blurlcChanged));
|
||||
origlcConn = origlc->signal_toggled().connect(sigc::mem_fun(*this, &Locallab::origlcChanged));
|
||||
csThreshold->setAdjusterListener(this);
|
||||
@ -2984,10 +3001,79 @@ pe(nullptr)
|
||||
if (complexsoft < 2) {
|
||||
contrastBox->pack_start(*fftwlc);
|
||||
}
|
||||
masklcCurveEditorG->setCurveListener(this);
|
||||
CCmasklcshape->setIdentityValue(0.);
|
||||
CCmasklcshape->setResetCurve(FlatCurveType(defSpot.CCmasklccurve.at(0)), defSpot.CCmasklccurve);
|
||||
|
||||
if (showtooltip) {
|
||||
CCmasklcshape->setTooltip(M("TP_LOCALLAB_CURVEEDITOR_CC_TOOLTIP"));
|
||||
}
|
||||
|
||||
CCmasklcshape->setBottomBarColorProvider(this, 7);
|
||||
|
||||
LLmasklcshape->setIdentityValue(0.);
|
||||
LLmasklcshape->setResetCurve(FlatCurveType(defSpot.LLmasklccurve.at(0)), defSpot.LLmasklccurve);
|
||||
|
||||
if (showtooltip) {
|
||||
LLmasklcshape->setTooltip(M("TP_LOCALLAB_CURVEEDITOR_CC_TOOLTIP"));
|
||||
}
|
||||
|
||||
LLmasklcshape->setBottomBarBgGradient(mllshape);
|
||||
|
||||
HHmasklcshape->setIdentityValue(0.);
|
||||
HHmasklcshape->setResetCurve(FlatCurveType(defSpot.HHmasklccurve.at(0)), defSpot.HHmasklccurve);
|
||||
|
||||
if (showtooltip) {
|
||||
HHmasklcshape->setTooltip(M("TP_LOCALLAB_CURVEEDITOR_CC_TOOLTIP"));
|
||||
}
|
||||
|
||||
HHmasklcshape->setCurveColorProvider(this, 6);
|
||||
HHmasklcshape->setBottomBarColorProvider(this, 6);
|
||||
|
||||
masklcCurveEditorG->curveListComplete();
|
||||
|
||||
enalcMaskConn = enalcMask->signal_toggled().connect(sigc::mem_fun(*this, &Locallab::enalcMaskChanged));
|
||||
|
||||
showmasklcMethod->append(M("TP_LOCALLAB_SHOWMNONE"));
|
||||
showmasklcMethod->append(M("TP_LOCALLAB_SHOWMODIF"));
|
||||
showmasklcMethod->append(M("TP_LOCALLAB_SHOWMODIFMASK"));
|
||||
showmasklcMethod->append(M("TP_LOCALLAB_SHOWMASK"));
|
||||
showmasklcMethod->append(M("TP_LOCALLAB_PREVIEWSEL"));
|
||||
showmasklcMethod->set_active(0);
|
||||
|
||||
if (showtooltip) {
|
||||
showmasklcMethod->set_tooltip_markup(M("TP_LOCALLAB_SHOWMASKCOL_TOOLTIP"));
|
||||
}
|
||||
|
||||
showmasklcMethodConn = showmasklcMethod->signal_changed().connect(sigc::mem_fun(*this, &Locallab::showmasklcMethodChanged));
|
||||
|
||||
ToolParamBlock* const masklcBox = Gtk::manage(new ToolParamBlock());
|
||||
masklcBox->pack_start(*showmasklcMethod, Gtk::PACK_SHRINK, 4);
|
||||
masklcBox->pack_start(*enalcMask, Gtk::PACK_SHRINK, 0);
|
||||
masklcBox->pack_start(*masklcCurveEditorG, Gtk::PACK_SHRINK, 4); // Padding is mandatory to correct behavior of curve editor
|
||||
// maskcbBox->pack_start(*blendmaskcb, Gtk::PACK_SHRINK, 0);
|
||||
// maskcbBox->pack_start(*radmaskcb, Gtk::PACK_SHRINK, 0);
|
||||
|
||||
if (complexsoft < 1) {
|
||||
// maskcbBox->pack_start(*lapmaskcb, Gtk::PACK_SHRINK, 0);
|
||||
}
|
||||
|
||||
// maskcbBox->pack_start(*chromaskcb, Gtk::PACK_SHRINK, 0);
|
||||
|
||||
// if (complexsoft < 2) {
|
||||
// maskcbBox->pack_start(*gammaskcb, Gtk::PACK_SHRINK, 0);
|
||||
// }
|
||||
|
||||
// if (complexsoft < 2) {
|
||||
// maskcbBox->pack_start(*slomaskcb, Gtk::PACK_SHRINK, 0);
|
||||
// }
|
||||
|
||||
expmasklc->add(*masklcBox, false);
|
||||
// contrastBox->pack_start(*expmasklc, false, false);
|
||||
expcontrast->add(*contrastBox, false);
|
||||
expcontrast->setLevel(2);
|
||||
|
||||
|
||||
panel->pack_start(*expcontrast, false, false);
|
||||
|
||||
// Contrast by detail levels
|
||||
@ -3681,6 +3767,7 @@ void Locallab::foldAllButMe(GdkEventButton* event, MyExpander *expander)
|
||||
expcurvcol->set_expanded(expcurvcol == expander);
|
||||
expmaskexp->set_expanded(expmaskexp == expander);
|
||||
expmasksh->set_expanded(expmasksh == expander);
|
||||
expmasklc->set_expanded(expmasklc == expander);
|
||||
expmaskcb->set_expanded(expmaskcb == expander);
|
||||
expretitools->set_expanded(expretitools == expander);
|
||||
expmaskreti->set_expanded(expmaskreti == expander);
|
||||
@ -3786,6 +3873,7 @@ void Locallab::writeOptions(std::vector<int> &tpOpen)
|
||||
tpOpen.push_back(expgradsh->get_expanded());
|
||||
tpOpen.push_back(expmasksh->get_expanded());
|
||||
tpOpen.push_back(expshadhigh->get_expanded());
|
||||
tpOpen.push_back(expmasklc->get_expanded());
|
||||
tpOpen.push_back(expmaskcb->get_expanded());
|
||||
tpOpen.push_back(expcbdl->get_expanded());
|
||||
tpOpen.push_back(expretitools->get_expanded());
|
||||
@ -3944,6 +4032,11 @@ void Locallab::refChanged(double huer, double lumar, double chromar)
|
||||
LLmaskvibshape->updateLocallabBackground(normLumar);
|
||||
HHmaskvibshape->updateLocallabBackground(normHuer);
|
||||
|
||||
// Update local contrast mask background
|
||||
CCmasklcshape->updateLocallabBackground(normChromar);
|
||||
LLmasklcshape->updateLocallabBackground(normLumar);
|
||||
HHmasklcshape->updateLocallabBackground(normHuer);
|
||||
|
||||
// Update CBDL mask background
|
||||
CCmaskcbshape->updateLocallabBackground(normChromar);
|
||||
LLmaskcbshape->updateLocallabBackground(normLumar);
|
||||
@ -3973,7 +4066,7 @@ void Locallab::refChanged(double huer, double lumar, double chromar)
|
||||
|
||||
void Locallab::updateToolState(std::vector<int> &tpOpen)
|
||||
{
|
||||
if (tpOpen.size() >= 32) {
|
||||
if (tpOpen.size() >= 33) {
|
||||
expsettings->setExpanded(tpOpen.at(0));
|
||||
expmaskcol->set_expanded(tpOpen.at(1));
|
||||
expmaskcol1->set_expanded(tpOpen.at(2));
|
||||
@ -3988,24 +4081,25 @@ void Locallab::updateToolState(std::vector<int> &tpOpen)
|
||||
expgradsh->set_expanded(tpOpen.at(11));
|
||||
expmasksh->set_expanded(tpOpen.at(12));
|
||||
expshadhigh->set_expanded(tpOpen.at(13));
|
||||
expmaskcb->set_expanded(tpOpen.at(14));
|
||||
expcbdl->set_expanded(tpOpen.at(15));
|
||||
expretitools->set_expanded(tpOpen.at(16));
|
||||
expmaskreti->set_expanded(tpOpen.at(17));
|
||||
expreti->set_expanded(tpOpen.at(18));
|
||||
expmasktm->set_expanded(tpOpen.at(19));
|
||||
exptonemap->set_expanded(tpOpen.at(20));
|
||||
expmaskbl->set_expanded(tpOpen.at(21));
|
||||
expgradvib->set_expanded(tpOpen.at(22));
|
||||
expmaskvib->set_expanded(tpOpen.at(23));
|
||||
expvibrance->set_expanded(tpOpen.at(24));
|
||||
expsoft->set_expanded(tpOpen.at(25));
|
||||
expblur->set_expanded(tpOpen.at(26));
|
||||
expsharp->set_expanded(tpOpen.at(27));
|
||||
expcontrastpyr->set_expanded(tpOpen.at(28));
|
||||
expcontrast->set_expanded(tpOpen.at(29));
|
||||
expdenoi->set_expanded(tpOpen.at(30));
|
||||
explog->set_expanded(tpOpen.at(31));
|
||||
expmasklc->set_expanded(tpOpen.at(14));
|
||||
expmaskcb->set_expanded(tpOpen.at(15));
|
||||
expcbdl->set_expanded(tpOpen.at(16));
|
||||
expretitools->set_expanded(tpOpen.at(17));
|
||||
expmaskreti->set_expanded(tpOpen.at(18));
|
||||
expreti->set_expanded(tpOpen.at(19));
|
||||
expmasktm->set_expanded(tpOpen.at(20));
|
||||
exptonemap->set_expanded(tpOpen.at(21));
|
||||
expmaskbl->set_expanded(tpOpen.at(22));
|
||||
expgradvib->set_expanded(tpOpen.at(23));
|
||||
expmaskvib->set_expanded(tpOpen.at(24));
|
||||
expvibrance->set_expanded(tpOpen.at(25));
|
||||
expsoft->set_expanded(tpOpen.at(26));
|
||||
expblur->set_expanded(tpOpen.at(27));
|
||||
expsharp->set_expanded(tpOpen.at(28));
|
||||
expcontrastpyr->set_expanded(tpOpen.at(29));
|
||||
expcontrast->set_expanded(tpOpen.at(30));
|
||||
expdenoi->set_expanded(tpOpen.at(31));
|
||||
explog->set_expanded(tpOpen.at(32));
|
||||
|
||||
}
|
||||
}
|
||||
@ -5150,6 +5244,11 @@ void Locallab::write(rtengine::procparams::ProcParams* pp, ParamsEdited* pedited
|
||||
pp->locallab.spots.at(pp->locallab.selspot).localcontMethod = "wav";
|
||||
}
|
||||
|
||||
pp->locallab.spots.at(pp->locallab.selspot).LLmasklccurve = LLmasklcshape->getCurve();
|
||||
pp->locallab.spots.at(pp->locallab.selspot).CCmasklccurve = CCmasklcshape->getCurve();
|
||||
pp->locallab.spots.at(pp->locallab.selspot).HHmasklccurve = HHmasklcshape->getCurve();
|
||||
pp->locallab.spots.at(pp->locallab.selspot).enalcMask = enalcMask->get_active();
|
||||
|
||||
// Contrast by detail levels
|
||||
pp->locallab.spots.at(pp->locallab.selspot).expcbdl = expcbdl->getEnabled();
|
||||
|
||||
@ -5543,6 +5642,13 @@ void Locallab::write(rtengine::procparams::ProcParams* pp, ParamsEdited* pedited
|
||||
pe->locallab.spots.at(pp->locallab.selspot).csthreshold = pe->locallab.spots.at(pp->locallab.selspot).csthreshold || csThreshold->getEditedState();
|
||||
pe->locallab.spots.at(pp->locallab.selspot).locconwavcurve = pe->locallab.spots.at(pp->locallab.selspot).locconwavcurve || !wavshapecon->isUnChanged();
|
||||
pe->locallab.spots.at(pp->locallab.selspot).loccompwavcurve = pe->locallab.spots.at(pp->locallab.selspot).loccompwavcurve || !wavshapecomp->isUnChanged();
|
||||
|
||||
pe->locallab.spots.at(pp->locallab.selspot).CCmasklccurve = pe->locallab.spots.at(pp->locallab.selspot).CCmasklccurve || !CCmasklcshape->isUnChanged();
|
||||
pe->locallab.spots.at(pp->locallab.selspot).LLmasklccurve = pe->locallab.spots.at(pp->locallab.selspot).LLmasklccurve || !LLmasklcshape->isUnChanged();
|
||||
pe->locallab.spots.at(pp->locallab.selspot).HHmasklccurve = pe->locallab.spots.at(pp->locallab.selspot).HHmasklccurve || !HHmasklcshape->isUnChanged();
|
||||
pe->locallab.spots.at(pp->locallab.selspot).enalcMask = pe->locallab.spots.at(pp->locallab.selspot).enalcMask || !enalcMask->get_inconsistent();
|
||||
|
||||
|
||||
// Contrast by detail levels
|
||||
pe->locallab.spots.at(pp->locallab.selspot).expcbdl = pe->locallab.spots.at(pp->locallab.selspot).expcbdl || !expcbdl->get_inconsistent();
|
||||
|
||||
@ -5938,6 +6044,12 @@ void Locallab::write(rtengine::procparams::ProcParams* pp, ParamsEdited* pedited
|
||||
pedited->locallab.spots.at(pp->locallab.selspot).csthreshold = pedited->locallab.spots.at(pp->locallab.selspot).csthreshold || csThreshold->getEditedState();
|
||||
pedited->locallab.spots.at(pp->locallab.selspot).locconwavcurve = pedited->locallab.spots.at(pp->locallab.selspot).locconwavcurve || !wavshapecon->isUnChanged();
|
||||
pedited->locallab.spots.at(pp->locallab.selspot).loccompwavcurve = pedited->locallab.spots.at(pp->locallab.selspot).loccompwavcurve || !wavshapecomp->isUnChanged();
|
||||
|
||||
pedited->locallab.spots.at(pp->locallab.selspot).CCmasklccurve = pedited->locallab.spots.at(pp->locallab.selspot).CCmasklccurve || !CCmasklcshape->isUnChanged();
|
||||
pedited->locallab.spots.at(pp->locallab.selspot).LLmasklccurve = pedited->locallab.spots.at(pp->locallab.selspot).LLmasklccurve || !LLmasklcshape->isUnChanged();
|
||||
pedited->locallab.spots.at(pp->locallab.selspot).HHmasklccurve = pedited->locallab.spots.at(pp->locallab.selspot).HHmasklccurve || !HHmasklcshape->isUnChanged();
|
||||
pedited->locallab.spots.at(pp->locallab.selspot).enalcMask = pedited->locallab.spots.at(pp->locallab.selspot).enalcMask || !enalcMask->get_inconsistent();
|
||||
|
||||
// Contrast by detail levels
|
||||
pedited->locallab.spots.at(pp->locallab.selspot).expcbdl = pedited->locallab.spots.at(pp->locallab.selspot).expcbdl || !expcbdl->get_inconsistent();
|
||||
|
||||
@ -6436,6 +6548,24 @@ void Locallab::curveChanged(CurveEditor* ce)
|
||||
}
|
||||
}
|
||||
|
||||
if (ce == CCmasklcshape) {
|
||||
if (listener) {
|
||||
listener->panelChanged(EvlocallabCCmasklcshape, M("HISTORY_CUSTOMCURVE"));
|
||||
}
|
||||
}
|
||||
|
||||
if (ce == LLmasklcshape) {
|
||||
if (listener) {
|
||||
listener->panelChanged(EvlocallabLLmasklcshape, M("HISTORY_CUSTOMCURVE"));
|
||||
}
|
||||
}
|
||||
|
||||
if (ce == HHmasklcshape) {
|
||||
if (listener) {
|
||||
listener->panelChanged(EvlocallabHHmasklcshape, M("HISTORY_CUSTOMCURVE"));
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
//denoise
|
||||
if (getEnabled() && expdenoi->getEnabled()) {
|
||||
@ -6804,6 +6934,7 @@ void Locallab::showmaskcolMethodChangedinv()
|
||||
showmaskSHMethod->set_active(0);
|
||||
showmaskSHMethodinv->set_active(0);
|
||||
showmaskvibMethod->set_active(0);
|
||||
showmasklcMethod->set_active(0);
|
||||
showmaskcbMethod->set_active(0);
|
||||
showmaskretiMethod->set_active(0);
|
||||
showmasksoftMethod->set_active(0);
|
||||
@ -6827,6 +6958,7 @@ void Locallab::showmaskexpMethodChangedinv()
|
||||
showmaskexpMethod->set_active(0);
|
||||
showmaskSHMethod->set_active(0);
|
||||
showmaskSHMethodinv->set_active(0);
|
||||
showmasklcMethod->set_active(0);
|
||||
showmaskcbMethod->set_active(0);
|
||||
showmaskvibMethod->set_active(0);
|
||||
showmaskretiMethod->set_active(0);
|
||||
@ -6849,6 +6981,7 @@ void Locallab::showmaskexpMethodChanged()
|
||||
showmaskexpMethodinv->set_active(0);
|
||||
showmaskcolMethodinv->set_active(0);
|
||||
showmaskcolMethod->set_active(0);
|
||||
showmasklcMethod->set_active(0);
|
||||
showmaskcbMethod->set_active(0);
|
||||
showmaskSHMethod->set_active(0);
|
||||
showmaskSHMethodinv->set_active(0);
|
||||
@ -6971,6 +7104,7 @@ void Locallab::showmaskSHMethodChanged()
|
||||
showmaskexpMethod->set_active(0);
|
||||
showmaskSHMethodinv->set_active(0);
|
||||
showmaskvibMethod->set_active(0);
|
||||
showmasklcMethod->set_active(0);
|
||||
showmaskcbMethod->set_active(0);
|
||||
showmaskretiMethod->set_active(0);
|
||||
showmasksoftMethod->set_active(0);
|
||||
@ -6994,6 +7128,7 @@ void Locallab::showmaskvibMethodChanged()
|
||||
showmaskcolMethod->set_active(0);
|
||||
showmaskexpMethod->set_active(0);
|
||||
showmaskSHMethodinv->set_active(0);
|
||||
showmasklcMethod->set_active(0);
|
||||
showmaskcbMethod->set_active(0);
|
||||
showmaskretiMethod->set_active(0);
|
||||
showmasksoftMethod->set_active(0);
|
||||
@ -7016,6 +7151,7 @@ void Locallab::showmaskSHMethodChangedinv()
|
||||
showmaskcolMethodinv->set_active(0);
|
||||
showmaskcolMethod->set_active(0);
|
||||
showmaskexpMethod->set_active(0);
|
||||
showmasklcMethod->set_active(0);
|
||||
showmaskcbMethod->set_active(0);
|
||||
showmaskvibMethod->set_active(0);
|
||||
showmaskretiMethod->set_active(0);
|
||||
@ -7029,6 +7165,32 @@ void Locallab::showmaskSHMethodChangedinv()
|
||||
}
|
||||
}
|
||||
|
||||
void Locallab::showmasklcMethodChanged()
|
||||
{
|
||||
// printf("showmaskSHMethodChanged\n");
|
||||
|
||||
// When one mask state is changed, other masks are deactivated
|
||||
disableListener();
|
||||
showmaskexpMethodinv->set_active(0);
|
||||
showmaskcolMethodinv->set_active(0);
|
||||
showmaskcolMethod->set_active(0);
|
||||
showmaskSHMethod->set_active(0);
|
||||
showmaskSHMethodinv->set_active(0);
|
||||
showmaskexpMethod->set_active(0);
|
||||
showmaskvibMethod->set_active(0);
|
||||
showmaskretiMethod->set_active(0);
|
||||
showmasksoftMethod->set_active(0);
|
||||
showmasktmMethod->set_active(0);
|
||||
showmaskblMethod->set_active(0);
|
||||
showmaskcbMethod->set_active(0);
|
||||
enableListener();
|
||||
|
||||
if (listener) {
|
||||
listener->panelChanged(EvlocallabshowmasklcMethod, "");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void Locallab::showmaskcbMethodChanged()
|
||||
{
|
||||
// printf("showmaskSHMethodChanged\n");
|
||||
@ -7045,6 +7207,7 @@ void Locallab::showmaskcbMethodChanged()
|
||||
showmaskretiMethod->set_active(0);
|
||||
showmasksoftMethod->set_active(0);
|
||||
showmasktmMethod->set_active(0);
|
||||
showmasklcMethod->set_active(0);
|
||||
showmaskblMethod->set_active(0);
|
||||
enableListener();
|
||||
|
||||
@ -7066,6 +7229,7 @@ void Locallab::showmaskblMethodChanged()
|
||||
showmaskSHMethodinv->set_active(0);
|
||||
showmaskexpMethod->set_active(0);
|
||||
showmaskvibMethod->set_active(0);
|
||||
showmasklcMethod->set_active(0);
|
||||
showmaskcbMethod->set_active(0);
|
||||
showmaskretiMethod->set_active(0);
|
||||
showmasksoftMethod->set_active(0);
|
||||
@ -7092,6 +7256,7 @@ void Locallab::showmasktmMethodChanged()
|
||||
showmaskSHMethodinv->set_active(0);
|
||||
showmaskvibMethod->set_active(0);
|
||||
showmaskexpMethod->set_active(0);
|
||||
showmasklcMethod->set_active(0);
|
||||
showmaskcbMethod->set_active(0);
|
||||
showmaskretiMethod->set_active(0);
|
||||
showmasksoftMethod->set_active(0);
|
||||
@ -7116,6 +7281,7 @@ void Locallab::showmaskretiMethodChanged()
|
||||
showmaskSHMethodinv->set_active(0);
|
||||
showmaskvibMethod->set_active(0);
|
||||
showmaskexpMethod->set_active(0);
|
||||
showmasklcMethod->set_active(0);
|
||||
showmaskcbMethod->set_active(0);
|
||||
showmasksoftMethod->set_active(0);
|
||||
showmasktmMethod->set_active(0);
|
||||
@ -7139,6 +7305,7 @@ void Locallab::showmasksoftMethodChanged()
|
||||
showmaskSHMethod->set_active(0);
|
||||
showmaskvibMethod->set_active(0);
|
||||
showmaskSHMethodinv->set_active(0);
|
||||
showmasklcMethod->set_active(0);
|
||||
showmaskcbMethod->set_active(0);
|
||||
showmaskretiMethod->set_active(0);
|
||||
showmasktmMethod->set_active(0);
|
||||
@ -7161,6 +7328,7 @@ void Locallab::resetMaskVisibility()
|
||||
showmaskSHMethod->set_active(0);
|
||||
showmaskvibMethod->set_active(0);
|
||||
showmaskSHMethodinv->set_active(0);
|
||||
showmasklcMethod->set_active(0);
|
||||
showmaskcbMethod->set_active(0);
|
||||
showmaskretiMethod->set_active(0);
|
||||
showmasksoftMethod->set_active(0);
|
||||
@ -7178,6 +7346,7 @@ Locallab::llMaskVisibility* Locallab::getMaskVisibility()
|
||||
maskStruct->SHMask = showmaskSHMethod->get_active_row_number();
|
||||
maskStruct->vibMask = showmaskvibMethod->get_active_row_number();
|
||||
maskStruct->SHMaskinv = showmaskSHMethodinv->get_active_row_number();
|
||||
maskStruct->lcMask = showmasklcMethod->get_active_row_number();
|
||||
maskStruct->cbMask = showmaskcbMethod->get_active_row_number();
|
||||
maskStruct->retiMask = showmaskretiMethod->get_active_row_number();
|
||||
maskStruct->softMask = showmasksoftMethod->get_active_row_number();
|
||||
@ -7591,6 +7760,31 @@ void Locallab::enaretiMasktmapChanged()
|
||||
}
|
||||
}
|
||||
|
||||
void Locallab::enalcMaskChanged()
|
||||
{
|
||||
// printf("enalcMaskChanged\n");
|
||||
|
||||
if (multiImage) {
|
||||
if (enalcMask->get_inconsistent()) {
|
||||
enalcMask->set_inconsistent(false);
|
||||
enalcMaskConn.block(true);
|
||||
enalcMask->set_active(false);
|
||||
enalcMaskConn.block(false);
|
||||
}
|
||||
}
|
||||
|
||||
if (getEnabled() && expcontrast->getEnabled()) {
|
||||
if (listener) {
|
||||
if (enalcMask->get_active()) {
|
||||
listener->panelChanged(EvLocallabEnalcMask, M("GENERAL_ENABLED"));
|
||||
} else {
|
||||
listener->panelChanged(EvLocallabEnalcMask, M("GENERAL_DISABLED"));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void Locallab::enacbMaskChanged()
|
||||
{
|
||||
// printf("enacbMaskChanged\n");
|
||||
@ -10723,6 +10917,7 @@ void Locallab::setBatchMode(bool batchMode)
|
||||
showmaskSHMethod->hide();
|
||||
showmaskSHMethodinv->hide();
|
||||
showmaskvibMethod->hide();
|
||||
showmasklcMethod->hide();
|
||||
showmaskcbMethod->hide();
|
||||
showmaskretiMethod->hide();
|
||||
showmasktmMethod->hide();
|
||||
@ -10941,6 +11136,8 @@ void Locallab::enableListener()
|
||||
fftwlcConn.block(false);
|
||||
blurlcConn.block(false);
|
||||
origlcConn.block(false);
|
||||
showmasklcMethodConn.block(false);
|
||||
enalcMaskConn.block(false);
|
||||
// Contrast by detail levels
|
||||
enablecbdlConn.block(false);
|
||||
enacbMaskConn.block(false);
|
||||
@ -11037,6 +11234,8 @@ void Locallab::disableListener()
|
||||
fftwlcConn.block(true);
|
||||
blurlcConn.block(true);
|
||||
origlcConn.block(true);
|
||||
showmasklcMethodConn.block(true);
|
||||
enalcMaskConn.block(true);
|
||||
// Contrast by detail levels
|
||||
enablecbdlConn.block(true);
|
||||
enacbMaskConn.block(true);
|
||||
@ -11728,6 +11927,11 @@ void Locallab::updateLocallabGUI(const rtengine::procparams::ProcParams* pp, con
|
||||
wavshapecon->setCurve(pp->locallab.spots.at(index).locconwavcurve);
|
||||
wavshapecomp->setCurve(pp->locallab.spots.at(index).loccompwavcurve);
|
||||
|
||||
CCmasklcshape->setCurve(pp->locallab.spots.at(index).CCmasklccurve);
|
||||
LLmasklcshape->setCurve(pp->locallab.spots.at(index).LLmasklccurve);
|
||||
HHmasklcshape->setCurve(pp->locallab.spots.at(index).HHmasklccurve);
|
||||
enalcMask->set_active(pp->locallab.spots.at(index).enalcMask);
|
||||
|
||||
if (fftwlc->get_active()) {
|
||||
lcradius->setLimits(20, 1000, 1, 80);
|
||||
} else {
|
||||
@ -12213,6 +12417,11 @@ void Locallab::updateLocallabGUI(const rtengine::procparams::ProcParams* pp, con
|
||||
wavshapecon->setUnChanged(!spotState->locconwavcurve);
|
||||
wavshapecomp->setUnChanged(!spotState->loccompwavcurve);
|
||||
|
||||
LLmasklcshape->setUnChanged(!spotState->LLmasklccurve);
|
||||
HHmasklcshape->setUnChanged(!spotState->HHmasklccurve);
|
||||
CCmasklcshape->setUnChanged(!spotState->CCmasklccurve);
|
||||
enalcMask->set_inconsistent(multiImage && !spotState->enalcMask);
|
||||
|
||||
if (!spotState->retinexMethod) {
|
||||
localcontMethod->set_active_text(M("GENERAL_UNCHANGED"));
|
||||
}
|
||||
|
@ -71,6 +71,7 @@ private:
|
||||
MyExpander* const expcurvcol;
|
||||
MyExpander* const expmaskexp;
|
||||
MyExpander* const expmasksh;
|
||||
MyExpander* const expmasklc;
|
||||
MyExpander* const expmaskcb;
|
||||
MyExpander* const expmaskreti;
|
||||
MyExpander* const expmasktm;
|
||||
@ -172,7 +173,11 @@ private:
|
||||
FlatCurveEditor* const wavshapecon;
|
||||
CurveEditorGroup* const LocalcurveEditorwavcomp;
|
||||
FlatCurveEditor* const wavshapecomp;
|
||||
|
||||
CurveEditorGroup* const masklcCurveEditorG;
|
||||
// DiagonalCurveEditor* const Lmasklcshape;
|
||||
FlatCurveEditor* const CCmasklcshape;
|
||||
FlatCurveEditor* const LLmasklcshape;
|
||||
FlatCurveEditor* const HHmasklcshape;
|
||||
//Cbdl
|
||||
CurveEditorGroup* const maskcbCurveEditorG;
|
||||
CurveEditorGroup* const mask2cbCurveEditorG;
|
||||
@ -476,6 +481,8 @@ private:
|
||||
sigc::connection blurlcConn;
|
||||
Gtk::CheckButton* const origlc;
|
||||
sigc::connection origlcConn;
|
||||
Gtk::CheckButton* const enalcMask;
|
||||
sigc::connection enalcMaskConn;
|
||||
|
||||
//CBDL
|
||||
Gtk::CheckButton* const enacbMask;
|
||||
@ -552,6 +559,10 @@ private:
|
||||
MyComboBoxText* const localcontMethod;
|
||||
sigc::connection localcontMethodConn;
|
||||
ThresholdAdjuster* const csThreshold;
|
||||
MyComboBoxText* const showmasklcMethod;
|
||||
sigc::connection showmasklcMethodConn;
|
||||
|
||||
|
||||
//CBDL
|
||||
MyComboBoxText* const showmaskcbMethod;
|
||||
sigc::connection showmaskcbMethodConn;
|
||||
@ -677,6 +688,7 @@ private:
|
||||
void fftwlcChanged();
|
||||
void blurlcChanged();
|
||||
void origlcChanged();
|
||||
void enalcMaskChanged();
|
||||
//CBDL
|
||||
void enacbMaskChanged();
|
||||
// ComboBox event functions
|
||||
@ -715,6 +727,7 @@ private:
|
||||
void showmaskretiMethodChanged();
|
||||
//Local contrast
|
||||
void localcontMethodChanged();
|
||||
void showmasklcMethodChanged();
|
||||
//CBDL
|
||||
void showmaskcbMethodChanged();
|
||||
//log encoding
|
||||
@ -764,6 +777,7 @@ public:
|
||||
int vibMask;
|
||||
int SHMask;
|
||||
int SHMaskinv;
|
||||
int lcMask;
|
||||
int cbMask;
|
||||
int retiMask;
|
||||
int softMask;
|
||||
|
@ -1279,6 +1279,12 @@ void ParamsEdited::initFrom(const std::vector<rtengine::procparams::ProcParams>&
|
||||
locallab.spots.at(j).locconwavcurve = locallab.spots.at(j).locconwavcurve && pSpot.locconwavcurve == otherSpot.locconwavcurve;
|
||||
locallab.spots.at(j).loccompwavcurve = locallab.spots.at(j).loccompwavcurve && pSpot.loccompwavcurve == otherSpot.loccompwavcurve;
|
||||
locallab.spots.at(j).csthreshold = locallab.spots.at(j).csthreshold && pSpot.csthreshold == otherSpot.csthreshold;
|
||||
|
||||
locallab.spots.at(j).CCmasklccurve = locallab.spots.at(j).CCmasklccurve && pSpot.CCmasklccurve == otherSpot.CCmasklccurve;
|
||||
locallab.spots.at(j).LLmasklccurve = locallab.spots.at(j).LLmasklccurve && pSpot.LLmasklccurve == otherSpot.LLmasklccurve;
|
||||
locallab.spots.at(j).HHmasklccurve = locallab.spots.at(j).HHmasklccurve && pSpot.HHmasklccurve == otherSpot.HHmasklccurve;
|
||||
locallab.spots.at(j).enalcMask = locallab.spots.at(j).enalcMask && pSpot.enalcMask == otherSpot.enalcMask;
|
||||
|
||||
// Contrast by detail levels
|
||||
locallab.spots.at(j).expcbdl = locallab.spots.at(j).expcbdl && pSpot.expcbdl == otherSpot.expcbdl;
|
||||
|
||||
@ -4080,6 +4086,22 @@ void ParamsEdited::combine(rtengine::procparams::ProcParams& toEdit, const rteng
|
||||
toEdit.locallab.spots.at(i).csthreshold = mods.locallab.spots.at(i).csthreshold;
|
||||
}
|
||||
|
||||
if (locallab.spots.at(i).CCmasklccurve) {
|
||||
toEdit.locallab.spots.at(i).CCmasklccurve = mods.locallab.spots.at(i).CCmasklccurve;
|
||||
}
|
||||
|
||||
if (locallab.spots.at(i).LLmasklccurve) {
|
||||
toEdit.locallab.spots.at(i).LLmasklccurve = mods.locallab.spots.at(i).LLmasklccurve;
|
||||
}
|
||||
|
||||
if (locallab.spots.at(i).HHmasklccurve) {
|
||||
toEdit.locallab.spots.at(i).HHmasklccurve = mods.locallab.spots.at(i).HHmasklccurve;
|
||||
}
|
||||
|
||||
if (locallab.spots.at(i).enalcMask) {
|
||||
toEdit.locallab.spots.at(i).enalcMask = mods.locallab.spots.at(i).enalcMask;
|
||||
}
|
||||
|
||||
// Contrast by detail levels
|
||||
if (locallab.spots.at(i).expcbdl) {
|
||||
toEdit.locallab.spots.at(i).expcbdl = mods.locallab.spots.at(i).expcbdl;
|
||||
@ -5570,6 +5592,11 @@ LocallabParamsEdited::LocallabSpotEdited::LocallabSpotEdited(bool v) :
|
||||
locconwavcurve(v),
|
||||
loccompwavcurve(v),
|
||||
csthreshold(v),
|
||||
CCmasklccurve(v),
|
||||
LLmasklccurve(v),
|
||||
HHmasklccurve(v),
|
||||
enalcMask(v),
|
||||
|
||||
// Contrast by detail levels
|
||||
expcbdl(v),
|
||||
mult{v, v, v, v, v, v},
|
||||
@ -5956,6 +5983,10 @@ void LocallabParamsEdited::LocallabSpotEdited::set(bool v)
|
||||
locconwavcurve = v;
|
||||
loccompwavcurve = v;
|
||||
csthreshold = v;
|
||||
CCmasklccurve = v;
|
||||
LLmasklccurve = v;
|
||||
HHmasklccurve = v;
|
||||
enalcMask = v;
|
||||
// Contrast by detail levels
|
||||
expcbdl = v;
|
||||
|
||||
|
@ -712,6 +712,10 @@ public:
|
||||
bool locconwavcurve;
|
||||
bool loccompwavcurve;
|
||||
bool csthreshold;
|
||||
bool CCmasklccurve;
|
||||
bool LLmasklccurve;
|
||||
bool HHmasklccurve;
|
||||
bool enalcMask;
|
||||
// Contrast by detail levels
|
||||
bool expcbdl;
|
||||
bool mult[6];
|
||||
|
Loading…
x
Reference in New Issue
Block a user