Haze removal - wrong colors in export

hi,

the explanation makes perfect sense. RT had the same problem, which I solved by using a fixed size image (independent of the current zoom level) to estimate the ambient light. (in fact, now that I mention it, I don’t remember whether I back ported this in the official version, I have to double check – though this is not relevant here…).

bottom line, I think using a downsampled image to estimate the ambient light would be a way to fix this, assuming this is feasible in darktable