Merge branch 'master' into gtk3

This commit is contained in:
Beep6581
2015-11-05 23:36:23 +01:00
48 changed files with 581 additions and 384 deletions

View File

@@ -94,7 +94,7 @@
#define ADDSET_WA_THRESHOLD2 86
#define ADDSET_WA_CHRO 87
#define ADDSET_WA_CHROMA 88
#define ADDSET_WA_CONTRAST 89
#define ADDSET_WA_CONTRAST 89
#define ADDSET_WA_RESCON 90
#define ADDSET_WA_RESCONH 91
#define ADDSET_WA_RESCHRO 92
@@ -107,17 +107,16 @@
#define ADDSET_WA_EDGEDETECTTHR2 99
#define ADDSET_WA_TMRS 100
#define ADDSET_WA_GAMMA 101
#define ADDSET_RETI_STR 102
#define ADDSET_RETI_SCAL 103
#define ADDSET_RETI_NEIGH 104
#define ADDSET_RETI_LIMD 105
#define ADDSET_RETI_GAIN 106
#define ADDSET_RETI_OFFS 107
#define ADDSET_RETI_VART 108
#define ADDSET_RETI_GAM 109
#define ADDSET_RETI_SLO 110
#define ADDSET_RETI_STR 102
#define ADDSET_RETI_NEIGH 103
#define ADDSET_RETI_LIMD 104
#define ADDSET_RETI_GAIN 105
#define ADDSET_RETI_OFFS 106
#define ADDSET_RETI_VART 107
#define ADDSET_RETI_GAM 108
#define ADDSET_RETI_SLO 109
// When adding items, make sure to update ADDSET_PARAM_NUM
#define ADDSET_PARAM_NUM 111 // THIS IS USED AS A DELIMITER!!
#define ADDSET_PARAM_NUM 110 // THIS IS USED AS A DELIMITER!!
#endif

View File

@@ -167,7 +167,7 @@ void BatchToolPanelCoordinator::initSession ()
blackwhite->setAdjusterBehavior (false, false);
colortoning->setAdjusterBehavior (false, false, false, false, false);
filmSimulation->setAdjusterBehavior(false);
retinex->setAdjusterBehavior (false, false, false, false, false, false, false, false, false);
retinex->setAdjusterBehavior (false, false, false, false, false, false, false, false);
shadowshighlights->setAdjusterBehavior (false, false, false);
dirpyrequalizer->setAdjusterBehavior (false, false, false);
@@ -204,7 +204,7 @@ void BatchToolPanelCoordinator::initSession ()
// colortoning->setAdjusterBehavior (options.baBehav[ADDSET_COLORTONING_SPLIT], options.baBehav[ADDSET_COLORTONING_SATTHRESHOLD], options.baBehav[ADDSET_COLORTONING_SATOPACITY], options.baBehav[ADDSET_COLORTONING_STRPROTECT], options.baBehav[ADDSET_COLORTONING_BALANCE]);
colortoning->setAdjusterBehavior (options.baBehav[ADDSET_COLORTONING_SPLIT], options.baBehav[ADDSET_COLORTONING_SATTHRESHOLD], options.baBehav[ADDSET_COLORTONING_SATOPACITY], options.baBehav[ADDSET_COLORTONING_STRENGTH], options.baBehav[ADDSET_COLORTONING_BALANCE]);
filmSimulation->setAdjusterBehavior(options.baBehav[ADDSET_FILMSIMULATION_STRENGTH]);
retinex->setAdjusterBehavior (options.baBehav[ADDSET_RETI_STR], options.baBehav[ADDSET_RETI_SCAL], options.baBehav[ADDSET_RETI_NEIGH], options.baBehav[ADDSET_RETI_LIMD], options.baBehav[ADDSET_RETI_GAIN], options.baBehav[ADDSET_RETI_OFFS], options.baBehav[ADDSET_RETI_VART], options.baBehav[ADDSET_RETI_GAM], options.baBehav[ADDSET_RETI_SLO]);
retinex->setAdjusterBehavior (options.baBehav[ADDSET_RETI_STR], options.baBehav[ADDSET_RETI_NEIGH], options.baBehav[ADDSET_RETI_LIMD], options.baBehav[ADDSET_RETI_GAIN], options.baBehav[ADDSET_RETI_OFFS], options.baBehav[ADDSET_RETI_VART], options.baBehav[ADDSET_RETI_GAM], options.baBehav[ADDSET_RETI_SLO]);
chmixer->setAdjusterBehavior (options.baBehav[ADDSET_CHMIXER] );
blackwhite->setAdjusterBehavior (options.baBehav[ADDSET_BLACKWHITE_HUES], options.baBehav[ADDSET_BLACKWHITE_GAMMA]);
@@ -582,10 +582,6 @@ void BatchToolPanelCoordinator::initSession ()
pparams.retinex.str = 0;
}
if (options.baBehav[ADDSET_RETI_SCAL]) {
pparams.retinex.scal = 0;
}
if (options.baBehav[ADDSET_RETI_NEIGH]) {
pparams.retinex.neigh = 0;
}

View File

@@ -615,10 +615,13 @@ int processLineParams( int argc, char **argv )
std::cout << " Preferences > Image Processing > Default Processing Profile" << std::endl;
std::cout << " -j[1-100] Specify output to be JPEG (on by default). Optionally add" << std::endl;
std::cout << " compression 1-100 (default value: 92)." << std::endl;
std::cout << " -js<1-3> Specify the JPEG subsampling parameter, where:" << std::endl;
std::cout << " 1 = Best compression: 2x2, 1x1, 1x1 (4:1:1) - default of the JPEG library" << std::endl;
std::cout << " 2 = Widely used normal ratio: 2x1, 1x1, 1x1 (4:2:2)" << std::endl;
std::cout << " 3 = Best quality: 1x1, 1x1, 1x1 (4:4:4)" << std::endl;
std::cout << " -js<1-3> Specify the JPEG chroma subsampling parameter, where:" << std::endl;
std::cout << " 1 = Best compression: 2x2, 1x1, 1x1 (4:2:0)" << std::endl;
std::cout << " Chroma halved vertically and horizontally." << std::endl;
std::cout << " 2 = Balanced: 2x1, 1x1, 1x1 (4:2:2)" << std::endl;
std::cout << " Chroma halved horizontally." << std::endl;
std::cout << " 3 = Best quality: 1x1, 1x1, 1x1 (4:4:4)" << std::endl;
std::cout << " No chroma subsampling." << std::endl;
std::cout << " -b<8|16> Specify bit depth per channel (only applies to TIFF and PNG output)." << std::endl;
std::cout << " -t[z] Specify output to be TIFF (16-bit if -b8 is not set)." << std::endl;
std::cout << " Uncompressed by default, or ZIP compression with 'z'" << std::endl;

View File

@@ -599,7 +599,6 @@ void Options::setDefaults ()
0, //ADDSET_WA_TMRS
0, //ADDSET_WA_GAMMA
0, //ADDSET_RETI_STR
0, //ADDSET_RETI_SCAL
0, //ADDSET_RETI_NEIGH
0, //ADDSET_RETI_LIMD
0, //ADDSET_RETI_GAIN

View File

@@ -1082,9 +1082,9 @@ void ParamsEdited::combine (rtengine::procparams::ProcParams& toEdit, const rten
toEdit.retinex.str = dontforceSet && options.baBehav[ADDSET_RETI_STR] ? toEdit.retinex.str + mods.retinex.str : mods.retinex.str;
}
if (retinex.scal) {
toEdit.retinex.scal = dontforceSet && options.baBehav[ADDSET_RETI_SCAL] ? toEdit.retinex.scal + mods.retinex.scal : mods.retinex.scal;
}
// if (retinex.scal) {
// toEdit.retinex.scal = dontforceSet && options.baBehav[ADDSET_RETI_SCAL] ? toEdit.retinex.scal + mods.retinex.scal : mods.retinex.scal;
// }
if (retinex.medianmap) {
toEdit.retinex.medianmap = mods.retinex.medianmap;
@@ -2702,4 +2702,4 @@ bool LensProfParamsEdited::isUnchanged() const
bool RetinexParamsEdited::isUnchanged() const
{
return enabled && retinexcolorspace && gammaretinex && gam && slope;
}
}

View File

@@ -172,13 +172,12 @@ Gtk::Widget* Preferences::getBatchProcPanel ()
mi->set_value (behavColumns.label, M("TP_RETINEX_LABEL"));
appendBehavList (mi, M("TP_RETINEX_STRENGTH"), ADDSET_RETI_STR, false);
appendBehavList (mi, M("TP_RETINEX_NEIGHBOR"), ADDSET_RETI_NEIGH, false);
appendBehavList (mi, M("TP_RETINEX_VARIANCE"), ADDSET_RETI_VART, false);
appendBehavList (mi, M("TP_RETINEX_GAMMA"), ADDSET_RETI_GAM, false);
appendBehavList (mi, M("TP_RETINEX_SLOPE"), ADDSET_RETI_SLO, false);
appendBehavList (mi, M("TP_RETINEX_SCALES"), ADDSET_RETI_SCAL, false);
appendBehavList (mi, M("TP_RETINEX_GAIN"), ADDSET_RETI_GAIN, false);
appendBehavList (mi, M("TP_RETINEX_OFFSET"), ADDSET_RETI_OFFS, false);
appendBehavList (mi, M("TP_RETINEX_THRESHOLD"), ADDSET_RETI_LIMD, false);
appendBehavList (mi, M("TP_RETINEX_VARIANCE"), ADDSET_RETI_VART, false);
mi = behModel->append ();
mi->set_value (behavColumns.label, M("TP_SHADOWSHLIGHTS_LABEL"));

View File

@@ -112,12 +112,12 @@ Retinex::Retinex () : FoldableToolPanel(this, "retinex", M("TP_RETINEX_LABEL"),
gammaretinexConn = gammaretinex->signal_changed().connect ( sigc::mem_fun(*this, &Retinex::gammaretinexChanged) );
gammaretinex->set_tooltip_markup (M("TP_RETINEX_GAMMA_TOOLTIP"));
gam = Gtk::manage (new Adjuster (M("TP_RETINEX_GAMMA"), 0.6, 3.0, 0.01, 1.30));
gam = Gtk::manage (new Adjuster (M("TP_RETINEX_FREEGAMMA"), 0.6, 3.0, 0.01, 1.30));
slope = Gtk::manage (new Adjuster (M("TP_RETINEX_SLOPE"), 1., 20., 0.1, 3.));
str = Gtk::manage (new Adjuster (M("TP_RETINEX_STRENGTH"), 0, 100., 1., 20.));
neigh = Gtk::manage (new Adjuster (M("TP_RETINEX_NEIGHBOR"), 6, 100., 1., 80.));
highl = Gtk::manage (new Adjuster (M("TP_RETINEX_HIGHLIGHT"), 1, 100, 1, 10));
highl = Gtk::manage (new Adjuster (M("TP_RETINEX_HIGHLIGHT"), 1, 20, 1, 4));
highl->set_tooltip_markup (M("TP_RETINEX_HIGHLIGHT_TOOLTIP"));
vart = Gtk::manage (new Adjuster (M("TP_RETINEX_VARIANCE"), 50, 500, 1, 200));
vart->set_tooltip_markup (M("TP_RETINEX_VARIANCE_TOOLTIP"));
@@ -808,11 +808,10 @@ void Retinex::setDefaults (const ProcParams* defParams, const ParamsEdited* pedi
}
}
void Retinex::setAdjusterBehavior (bool strAdd, bool neighAdd, bool scalAdd, bool limdAdd, bool gainAdd, bool offsAdd, bool vartAdd, bool gamAdd, bool slopeAdd)
void Retinex::setAdjusterBehavior (bool strAdd, bool neighAdd, bool limdAdd, bool gainAdd, bool offsAdd, bool vartAdd, bool gamAdd, bool slopeAdd)
{
str->setAddMode(strAdd);
neigh->setAddMode(neighAdd);
scal->setAddMode(scalAdd);
limd->setAddMode(limdAdd);
gain->setAddMode(gainAdd);
offs->setAddMode(offsAdd);

View File

@@ -97,7 +97,7 @@ public:
void ColorSpaceUpdateUI();
void writeOptions (std::vector<int> &tpOpen);
void updateToolState (std::vector<int> &tpOpen);
void setAdjusterBehavior (bool strAdd, bool neighAdd, bool scalAdd, bool limdAdd, bool gainAdd, bool offsAdd, bool vartAdd, bool gamAdd, bool slopeAdd);
void setAdjusterBehavior (bool strAdd, bool neighAdd, bool limdAdd, bool gainAdd, bool offsAdd, bool vartAdd, bool gamAdd, bool slopeAdd);
void updateCurveBackgroundHistogram (LUTu & histToneCurve, LUTu & histLCurve, LUTu & histCCurve,/* LUTu & histCLurve, LUTu & histLLCurve,*/ LUTu & histLCAM, LUTu & histCCAM, LUTu & histRed, LUTu & histGreen, LUTu & histBlue, LUTu & histLuma, LUTu & histLRETI);
virtual void colorForValue (double valX, double valY, enum ColorCaller::ElemType elemType, int callerId, ColorCaller* caller);