http://bugs.winehq.org/show_bug.cgi?id=23906
--- Comment #23 from Erich Hoover ehoover@mines.edu 2011-01-26 23:55:20 CST --- Created an attachment (id=33002) --> (http://bugs.winehq.org/attachment.cgi?id=33002) Minimalist hack around fog problem
I took a look at commit 4936e71828669ef084f9cf243f924a11a2cdce50 and stepped through the changes to find the one piece that causes the fog problem in SC2. A hack to revert the relevant piece is attached here. I'm not really familiar with GLSL, but if I had to guess (from my knowledge of floating point numbers) I'd say that it's probably a signedness problem. The old code always assumed that any division by zero should result in an infinity-equivalent; however, with IEEE floating point numbers a division by minus zero returns a minus infinity. So, if in the new code we end up dividing by a minus zero then we would get the "wrong" infinity.