Fix inaccurate RGB grey WB preview after using ITC
The RGB grey automatic white balance algorithm caches the multipliers. Temperature correlation automatic white balance also caches results to the same location, but never uses it. This causes the RGB grey method to produce incorrect results in the editor. Removing the temperature correlation cache fixes the issue and does not have side-effects.
This commit is contained in:
parent
f4dc5685f7
commit
05acfd510e
|
@ -7691,12 +7691,7 @@ void RawImageSource::getAutoWBMultipliersitc(bool extra, double & tempref, doubl
|
|||
printf("RGB grey AVG: %g %g %g\n", avg_r / std::max(1, rn), avg_g / std::max(1, gn), avg_b / std::max(1, bn));
|
||||
}
|
||||
|
||||
if (wbpar.method == "autitcgreen") {
|
||||
//not used
|
||||
redAWBMul = rm = avg_rm * refwb_red;
|
||||
greenAWBMul = gm = avg_gm * refwb_green;
|
||||
blueAWBMul = bm = avg_bm * refwb_blue;
|
||||
} else {
|
||||
if (wbpar.method != "autitcgreen") {
|
||||
const double reds = avg_r / std::max(1, rn) * refwb_red;
|
||||
const double greens = avg_g / std::max(1, gn) * refwb_green;
|
||||
const double blues = avg_b / std::max(1, bn) * refwb_blue;
|
||||
|
|
Loading…
Reference in New Issue