raw ca correction: first try to avoid colour shift, #4777

This commit is contained in:
heckflosse
2018-09-06 13:52:48 +02:00
parent f6195877e5
commit bcc7a3fb85
11 changed files with 84 additions and 7 deletions

View File

@@ -431,6 +431,7 @@ void ParamsEdited::set(bool v)
raw.xtranssensor.exBlackGreen = v;
raw.xtranssensor.exBlackBlue = v;
raw.ca_autocorrect = v;
raw.ca_avoidcolourshift = v;
raw.caautoiterations = v;
raw.cablue = v;
raw.cared = v;
@@ -987,6 +988,7 @@ void ParamsEdited::initFrom(const std::vector<rtengine::procparams::ProcParams>&
raw.xtranssensor.exBlackGreen = raw.xtranssensor.exBlackGreen && p.raw.xtranssensor.blackgreen == other.raw.xtranssensor.blackgreen;
raw.xtranssensor.exBlackBlue = raw.xtranssensor.exBlackBlue && p.raw.xtranssensor.blackblue == other.raw.xtranssensor.blackblue;
raw.ca_autocorrect = raw.ca_autocorrect && p.raw.ca_autocorrect == other.raw.ca_autocorrect;
raw.ca_avoidcolourshift = raw.ca_avoidcolourshift && p.raw.ca_avoidcolourshift == other.raw.ca_avoidcolourshift;
raw.caautoiterations = raw.caautoiterations && p.raw.caautoiterations == other.raw.caautoiterations;
raw.cared = raw.cared && p.raw.cared == other.raw.cared;
raw.cablue = raw.cablue && p.raw.cablue == other.raw.cablue;
@@ -2628,6 +2630,10 @@ void ParamsEdited::combine(rtengine::procparams::ProcParams& toEdit, const rteng
toEdit.raw.ca_autocorrect = mods.raw.ca_autocorrect;
}
if (raw.ca_avoidcolourshift) {
toEdit.raw.ca_avoidcolourshift = mods.raw.ca_avoidcolourshift;
}
if (raw.caautoiterations) {
toEdit.raw.caautoiterations = dontforceSet && options.baBehav[ADDSET_RAWCACORR] ? toEdit.raw.caautoiterations + mods.raw.caautoiterations : mods.raw.caautoiterations;
}
@@ -3133,7 +3139,7 @@ bool RAWParamsEdited::XTransSensor::isUnchanged() const
bool RAWParamsEdited::isUnchanged() const
{
return bayersensor.isUnchanged() && xtranssensor.isUnchanged() && ca_autocorrect && caautoiterations && cared && cablue && hotPixelFilter && deadPixelFilter && hotdeadpix_thresh && darkFrame
return bayersensor.isUnchanged() && xtranssensor.isUnchanged() && ca_autocorrect && ca_avoidcolourshift && caautoiterations && cared && cablue && hotPixelFilter && deadPixelFilter && hotdeadpix_thresh && darkFrame
&& df_autoselect && ff_file && ff_AutoSelect && ff_BlurRadius && ff_BlurType && exPos && exPreser && ff_AutoClipControl && ff_clipControl;
}