Improve Inverse Color Light and fixed some bugs

This commit is contained in:
Desmis
2017-11-26 09:21:39 +01:00
parent d13b485eff
commit 5e93f6ba5d
5 changed files with 4406 additions and 3442 deletions

View File

@@ -4,5 +4,5 @@ indent-switches
break-blocks
pad-oper
convert-tabs
pad-first-paren-out
pad-header
unpad-paren

View File

@@ -303,7 +303,8 @@ public:
void BlurNoise_Local(int call, LabImage* tmp1, LabImage* tmp2, float ** buflight, float ** bufchro, const float hueplus, const float huemoins, const float hueref, const float dhue, const float chromaref, const float lumaref, const local_params& lp, LabImage* original, LabImage* transformed, int cx, int cy);
void TM_Local(LabImage* tmp1, float ** buflight, const float hueplus, const float huemoins, const float hueref, const float dhue, const float chromaref, const float lumaref, const local_params& lp, LabImage* original, LabImage* transformed, int cx, int cy);
static void strcurv_data(std::string retistr, int *s_datc, int &siz);
void InverseContrast_Local (float ave, const struct local_contra& lco, const struct local_params& lp, LabImage* original, LabImage* transformed, int cx, int cy);
void InverseContrast_Local(float ave, struct local_contra & lco, const struct local_params & lp, const float hueplus, const float huemoins, const float hueref, const float dhue, const float chromaref, const float lumaref, LabImage * original, LabImage * transformed, int cx, int cy);
void vibrancelocal(int bfw, int bfh, LabImage* lab, LabImage* dest, bool & localskutili, LUTf & sklocalcurve);
void Expose_Local(int sen, float **buflight, float **bufchro, const float hueplus, const float huemoins, const float hueref, const float dhue, const float chromaref, const float lumaref, const struct local_params & lp, LabImage * original, LabImage * transformed, const LabImage * const tmp1, int cx, int cy);
void exlabLocal(const local_params& lp, int bfh, int bfw, LabImage* bufexporig, LabImage* lab, LUTf & hltonecurve, LUTf & shtonecurve, LUTf & tonecurve);
@@ -312,7 +313,7 @@ public:
void DeNoise_Local(int call, const struct local_params& lp, LabImage* original, LabImage* transformed, const LabImage &tmp1, int cx, int cy);
void ColorLight_Local(int call, LabImage * bufcolorig, float **buflight, float **bufchro, float **bufchroslid, float ** bufhh, float ** buflightslid, bool &LHutili, bool &HHutili, const float hueplus, const float huemoins, const float hueref, const float dhue, const float chromaref, const float lumaref, LUTf & lllocalcurve, const LocLHCurve & loclhCurve, const LocHHCurve & lochhCurve, const local_params& lp, LabImage* original, LabImage* transformed, int cx, int cy);
void InverseColorLight_Local (const struct local_params& lp, LabImage* original, LabImage* transformed, int cx, int cy);
void InverseColorLight_Local(const struct local_params& lp, LabImage* original, LabImage* transformed, int cx, int cy, const float hueplus, const float huemoins, const float hueref, const float dhue, const float chromaref, const float lumaref);
void Sharp_Local(int call, float **loctemp, const float hueplus, const float huemoins, const float hueref, const float dhue, const float chromaref, const local_params& lp, LabImage* original, LabImage* transformed, int cx, int cy);
void InverseSharp_Local(float **loctemp, const float hueplus, const float huemoins, const float hueref, const float dhue, const float chromaref, const local_params& lp, LabImage* original, LabImage* transformed, int cx, int cy);

File diff suppressed because it is too large Load Diff

View File

@@ -39,7 +39,7 @@ extern Options options;
Locallab::Locallab():
FoldableToolPanel (this, "locallab", M ("TP_LOCALLAB_LABEL"), false, true),
FoldableToolPanel(this, "locallab", M("TP_LOCALLAB_LABEL"), true, true),
EditSubscriber(ET_OBJECTS), lastObject(-1),
expcolor(new MyExpander(true, M("TP_LOCALLAB_COFR"))),
expexpose(new MyExpander(true, M("TP_LOCALLAB_EXPOSE"))),
@@ -67,7 +67,7 @@ Locallab::Locallab ():
centerY(Gtk::manage(new Adjuster(M("TP_LOCALLAB_CENTER_Y"), -1000, 1000, 1, 0))),
circrad(Gtk::manage(new Adjuster(M("TP_LOCALLAB_CIRCRADIUS"), 2, 150, 1, 18))),
sensiexclu(Gtk::manage(new Adjuster(M("TP_LOCALLAB_SENSIEXCLU"), 0, 100, 1, 19))),
struc (Gtk::manage (new Adjuster (M ("TP_LOCALLAB_STRUC"), 0, 400, 1, 0))),
struc(Gtk::manage(new Adjuster(M("TP_LOCALLAB_STRUC"), 0, 5, 1, 0))),
thres(Gtk::manage(new Adjuster(M("TP_LOCALLAB_THRES"), 1, 35, 1, 18))),
proxi(Gtk::manage(new Adjuster(M("TP_LOCALLAB_PROXI"), 0, 60, 1, 0))),
lightness(Gtk::manage(new Adjuster(M("TP_LOCALLAB_LIGHTNESS"), -100, 100, 1, 0))),
@@ -3432,11 +3432,12 @@ void Locallab::inversChanged ()
}
if (invers->get_active()) {
sensi->hide();
//sensi->hide();
sensi->show();
llCurveEditorG->hide();
curvactiv->hide();
qualitycurveMethod->hide();
artifFrame->hide();
artifFrame->show();
labqualcurv->hide();
} else {

View File

@@ -72,10 +72,12 @@ ToolPanelCoordinator::ToolPanelCoordinator (bool batch) : ipc (nullptr), hasChan
prsharpening = Gtk::manage (new PrSharpening());
crop = Gtk::manage (new Crop ());
icm = Gtk::manage (new ICMPanel ());
if (!batch) {
exifpanel = Gtk::manage (new ExifPanel ());
iptcpanel = Gtk::manage (new IPTCPanel ());
}
wavelet = Gtk::manage (new Wavelet ());
dirpyrequalizer = Gtk::manage (new DirPyrEqualizer ());
hsvequalizer = Gtk::manage (new HSVEqualizer ());
@@ -165,6 +167,7 @@ ToolPanelCoordinator::ToolPanelCoordinator (bool batch) : ipc (nullptr), hasChan
} else {
metadataPanel = nullptr;
}
toolPanelNotebook = new Gtk::Notebook ();
toolPanelNotebook->set_name ("ToolPanelNotebook");
@@ -226,6 +229,7 @@ ToolPanelCoordinator::ToolPanelCoordinator (bool batch) : ipc (nullptr), hasChan
toiL = Gtk::manage (new TextOrIcon ("openhand.png", M ("MAIN_TAB_LOCALLAB"), M ("MAIN_TAB_LOCALLAB_TOOLTIP"), type));
toiT = Gtk::manage (new TextOrIcon ("transform.png", M ("MAIN_TAB_TRANSFORM"), M ("MAIN_TAB_TRANSFORM_TOOLTIP"), type));
toiR = Gtk::manage (new TextOrIcon ("raw.png", M ("MAIN_TAB_RAW"), M ("MAIN_TAB_RAW_TOOLTIP"), type));
if (!batch) {
toiM = Gtk::manage (new TextOrIcon ("meta.png", M ("MAIN_TAB_METADATA"), M ("MAIN_TAB_METADATA_TOOLTIP"), type));
} else {
@@ -239,6 +243,7 @@ ToolPanelCoordinator::ToolPanelCoordinator (bool batch) : ipc (nullptr), hasChan
toolPanelNotebook->append_page (*locallabPanelSW, *toiL);
toolPanelNotebook->append_page (*transformPanelSW, *toiT);
toolPanelNotebook->append_page (*rawPanelSW, *toiR);
if (!batch) {
toolPanelNotebook->append_page (*metadataPanel, *toiM);
}
@@ -565,11 +570,13 @@ void ToolPanelCoordinator::updateToolState()
temp.push_back (options.tpOpen.at (i + expList.size()));
}
locallab->updateToolState (temp);
locallab->setExpanded (true);
wavelet->updateToolState (temp);
wavelet->setExpanded (true);
retinex->updateToolState (temp);
locallab->updateToolState (temp);
locallab->setExpanded (true);
}
}