On 14 June 2013 22:34, Stefan Dösinger <stefan(a)codeweavers.com> wrote:
+ { + float increase = eps; + volatile float fogend2 = fogend; + do + { + fogend2 += increase; + increase *= 2.0f; + } + while (fogstart == fogend2); + fogend = fogend2; + } Why is this needed? When end == start I'd expect (end - c) / (end - start) to evaluate to +/-INF, and then get clamped to [0, 1], which is pretty much what you'd want. In my (very limited) testing, that's also what actually happens with at least the GLSL backend.