http://bugs.winehq.org/show_bug.cgi?id=20053
--- Comment #18 from Henri Verbeet hverbeet@gmail.com 2010-01-04 12:39:16 --- (In reply to comment #17)
As far as I understand it: Drivers up to 180.60 returned INF on divide by zero in shaders. Newer ones return NaN, which directx does not expect, causing issues. This hack changes the particular offending shader path to check for div by zero and make sure it generates INF. It does not fix the problem in general, just masks it, hence, a hack.
The problem with the hack is mostly that it returns 0.0 instead of +INF. The problem with writing a proper fix is that I don't know a practical/reliable way to generate +INF in GLSL.
For what it's worth, the main difference between NaN and +INF that TF2 cares about is that NaN keeps propagating while e.g. "clamp(+INF, 0.0, 1.0);" returns 1.0.