Color Toning issue2014

This commit is contained in:
jdc
2014-07-07 19:44:32 +02:00
parent 7636502a7c
commit f277afd333
103 changed files with 4779 additions and 455 deletions

View File

@@ -67,6 +67,33 @@ void ParamsEdited::set (bool v) {
rgbCurves.rcurve = v;
rgbCurves.gcurve = v;
rgbCurves.bcurve = v;
colorToning.enabled = v;
colorToning.autosat = v;
colorToning.opacityCurve = v;
colorToning.colorCurve = v;
colorToning.satProtectionThreshold = v;
colorToning.saturatedOpacity = v;
colorToning.strengthprotection = v;
colorToning.shadowsColSat = v;
colorToning.hlColSat = v;
colorToning.balance = v;
colorToning.clcurve = v;
colorToning.method = v;
colorToning.twocolor = v;
colorToning.cl2curve = v;
colorToning.redlow = v;
colorToning.greenlow = v;
colorToning.bluelow = v;
colorToning.satlow = v;
colorToning.sathigh = v;
colorToning.redmed = v;
colorToning.greenmed = v;
colorToning.bluemed = v;
colorToning.redhigh = v;
colorToning.greenhigh = v;
colorToning.bluehigh = v;
colorToning.lumamode = v;
sharpening.enabled = v;
sharpening.radius = v;
sharpening.amount = v;
@@ -355,6 +382,32 @@ void ParamsEdited::initFrom (const std::vector<rtengine::procparams::ProcParams>
rgbCurves.rcurve = rgbCurves.rcurve && p.rgbCurves.rcurve == other.rgbCurves.rcurve;
rgbCurves.gcurve = rgbCurves.gcurve && p.rgbCurves.gcurve == other.rgbCurves.gcurve;
rgbCurves.bcurve = rgbCurves.bcurve && p.rgbCurves.bcurve == other.rgbCurves.bcurve;
colorToning.enabled = colorToning.enabled && p.colorToning.enabled == other.colorToning.enabled;
colorToning.twocolor = colorToning.twocolor && p.colorToning.twocolor == other.colorToning.twocolor;
colorToning.opacityCurve = colorToning.opacityCurve && p.colorToning.opacityCurve == other.colorToning.opacityCurve;
colorToning.colorCurve = colorToning.colorCurve && p.colorToning.colorCurve == other.colorToning.colorCurve;
colorToning.autosat = colorToning.autosat && p.colorToning.autosat == other.colorToning.autosat;
colorToning.satProtectionThreshold = colorToning.satProtectionThreshold && p.colorToning.satProtectionThreshold == other.colorToning.satProtectionThreshold;
colorToning.saturatedOpacity = colorToning.saturatedOpacity && p.colorToning.saturatedOpacity == other.colorToning.saturatedOpacity;
colorToning.strengthprotection = colorToning.strengthprotection && p.colorToning.strengthprotection == other.colorToning.strengthprotection;
colorToning.shadowsColSat = colorToning.shadowsColSat && p.colorToning.shadowsColSat == other.colorToning.shadowsColSat;
colorToning.hlColSat = colorToning.hlColSat && p.colorToning.hlColSat == other.colorToning.hlColSat;
colorToning.balance = colorToning.balance && p.colorToning.balance == other.colorToning.balance;
colorToning.clcurve = colorToning.clcurve && p.colorToning.clcurve == other.colorToning.clcurve;
colorToning.cl2curve = colorToning.cl2curve && p.colorToning.cl2curve == other.colorToning.cl2curve;
colorToning.method = colorToning.method && p.colorToning.method == other.colorToning.method;
colorToning.redlow = colorToning.redlow && p.colorToning.redlow == other.colorToning.redlow;
colorToning.greenlow = colorToning.greenlow && p.colorToning.greenlow == other.colorToning.greenlow;
colorToning.bluelow = colorToning.bluelow && p.colorToning.bluelow == other.colorToning.bluelow;
colorToning.satlow = colorToning.satlow && p.colorToning.satlow == other.colorToning.satlow;
colorToning.sathigh = colorToning.sathigh && p.colorToning.sathigh == other.colorToning.sathigh;
colorToning.redmed = colorToning.redmed && p.colorToning.redmed == other.colorToning.redmed;
colorToning.greenmed = colorToning.greenmed && p.colorToning.greenmed == other.colorToning.greenmed;
colorToning.bluemed = colorToning.bluemed && p.colorToning.bluemed == other.colorToning.bluemed;
colorToning.redhigh = colorToning.redhigh && p.colorToning.redhigh == other.colorToning.redhigh;
colorToning.greenhigh = colorToning.greenhigh && p.colorToning.greenhigh == other.colorToning.greenhigh;
colorToning.bluehigh = colorToning.bluehigh && p.colorToning.bluehigh == other.colorToning.bluehigh;
colorToning.lumamode = colorToning.lumamode && p.colorToning.lumamode == other.colorToning.lumamode;
sharpenEdge.enabled = sharpenEdge.enabled && p.sharpenEdge.enabled == other.sharpenEdge.enabled;
sharpenEdge.passes = sharpenEdge.passes && p.sharpenEdge.passes == other.sharpenEdge.passes;
sharpenEdge.amount = sharpenEdge.amount && p.sharpenEdge.amount == other.sharpenEdge.amount;
@@ -642,6 +695,37 @@ void ParamsEdited::combine (rtengine::procparams::ProcParams& toEdit, const rten
if (rgbCurves.gcurve) toEdit.rgbCurves.gcurve = mods.rgbCurves.gcurve;
if (rgbCurves.bcurve) toEdit.rgbCurves.bcurve = mods.rgbCurves.bcurve;
if (colorToning.enabled) toEdit.colorToning.enabled = mods.colorToning.enabled;
if (colorToning.twocolor) toEdit.colorToning.twocolor = mods.colorToning.twocolor;
if (colorToning.opacityCurve) toEdit.colorToning.opacityCurve = mods.colorToning.opacityCurve;
if (colorToning.colorCurve) toEdit.colorToning.colorCurve = mods.colorToning.colorCurve;
if (colorToning.enabled) toEdit.colorToning.enabled = mods.colorToning.enabled;
if (colorToning.opacityCurve) toEdit.colorToning.opacityCurve = mods.colorToning.opacityCurve;
if (colorToning.colorCurve) toEdit.colorToning.colorCurve = mods.colorToning.colorCurve;
if (colorToning.satProtectionThreshold) toEdit.colorToning.satProtectionThreshold = dontforceSet && options.baBehav[ADDSET_COLORTONING_SATTHRESHOLD] ? toEdit.colorToning.satProtectionThreshold + mods.colorToning.satProtectionThreshold : mods.colorToning.satProtectionThreshold;
if (colorToning.autosat) toEdit.colorToning.autosat = mods.colorToning.autosat;
if (colorToning.saturatedOpacity) toEdit.colorToning.saturatedOpacity = dontforceSet && options.baBehav[ADDSET_COLORTONING_SATOPACITY] ? toEdit.colorToning.saturatedOpacity + mods.colorToning.saturatedOpacity : mods.colorToning.saturatedOpacity;
if (colorToning.strengthprotection) toEdit.colorToning.strengthprotection = dontforceSet && options.baBehav[ADDSET_COLORTONING_STRPROTECT] ? toEdit.colorToning.strengthprotection + mods.colorToning.strengthprotection: mods.colorToning.strengthprotection;
if (colorToning.shadowsColSat) toEdit.colorToning.shadowsColSat = mods.colorToning.shadowsColSat;
if (colorToning.hlColSat) toEdit.colorToning.hlColSat = mods.colorToning.hlColSat;
if (colorToning.balance) toEdit.colorToning.balance = dontforceSet && options.baBehav[ADDSET_COLORTONING_BALANCE] ? toEdit.colorToning.balance + mods.colorToning.balance : mods.colorToning.balance;
if (colorToning.clcurve) toEdit.colorToning.clcurve = mods.colorToning.clcurve;
if (colorToning.method) toEdit.colorToning.method = mods.colorToning.method;
if (colorToning.cl2curve) toEdit.colorToning.cl2curve = mods.colorToning.cl2curve;
if (colorToning.lumamode) toEdit.colorToning.lumamode = mods.colorToning.lumamode;
if (colorToning.satlow) toEdit.colorToning.satlow = dontforceSet && options.baBehav[ADDSET_COLORTONING_SPLIT] ? toEdit.colorToning.satlow + mods.colorToning.satlow : mods.colorToning.satlow;
if (colorToning.sathigh) toEdit.colorToning.sathigh = dontforceSet && options.baBehav[ADDSET_COLORTONING_SPLIT] ? toEdit.colorToning.sathigh + mods.colorToning.sathigh : mods.colorToning.sathigh;
if (colorToning.redlow) toEdit.colorToning.redlow = dontforceSet && options.baBehav[ADDSET_COLORTONING_SPLIT] ? toEdit.colorToning.redlow + mods.colorToning.redlow : mods.colorToning.redlow;
if (colorToning.greenlow) toEdit.colorToning.greenlow = dontforceSet && options.baBehav[ADDSET_COLORTONING_SPLIT] ? toEdit.colorToning.greenlow + mods.colorToning.greenlow : mods.colorToning.greenlow;
if (colorToning.bluelow) toEdit.colorToning.bluelow = dontforceSet && options.baBehav[ADDSET_COLORTONING_SPLIT] ? toEdit.colorToning.bluelow + mods.colorToning.bluelow : mods.colorToning.bluelow;
if (colorToning.redmed) toEdit.colorToning.redmed = dontforceSet && options.baBehav[ADDSET_COLORTONING_SPLIT] ? toEdit.colorToning.redmed + mods.colorToning.redmed : mods.colorToning.redmed;
if (colorToning.greenmed) toEdit.colorToning.greenmed = dontforceSet && options.baBehav[ADDSET_COLORTONING_SPLIT] ? toEdit.colorToning.greenmed + mods.colorToning.greenmed : mods.colorToning.greenmed;
if (colorToning.bluemed) toEdit.colorToning.bluemed = dontforceSet && options.baBehav[ADDSET_COLORTONING_SPLIT] ? toEdit.colorToning.bluemed + mods.colorToning.bluemed : mods.colorToning.bluemed;
if (colorToning.redhigh) toEdit.colorToning.redhigh = dontforceSet && options.baBehav[ADDSET_COLORTONING_SPLIT] ? toEdit.colorToning.redhigh + mods.colorToning.redhigh : mods.colorToning.redhigh;
if (colorToning.greenhigh) toEdit.colorToning.greenhigh= dontforceSet && options.baBehav[ADDSET_COLORTONING_SPLIT] ? toEdit.colorToning.greenhigh + mods.colorToning.greenhigh : mods.colorToning.greenhigh;
if (colorToning.bluehigh) toEdit.colorToning.bluehigh = dontforceSet && options.baBehav[ADDSET_COLORTONING_SPLIT] ? toEdit.colorToning.bluehigh + mods.colorToning.bluehigh : mods.colorToning.bluehigh;
if (sharpenEdge.enabled) toEdit.sharpenEdge.enabled = mods.sharpenEdge.enabled;
if (sharpenEdge.passes) toEdit.sharpenEdge.passes = dontforceSet && options.baBehav[ADDSET_SHARPENEDGE_PASS] ? toEdit.sharpenEdge.passes + mods.sharpenEdge.passes : mods.sharpenEdge.passes;
if (sharpenEdge.amount) toEdit.sharpenEdge.amount = dontforceSet && options.baBehav[ADDSET_SHARPENEDGE_AMOUNT] ? toEdit.sharpenEdge.amount + mods.sharpenEdge.amount : mods.sharpenEdge.amount;