http://bugs.winehq.org/show_bug.cgi?id=28945
--- Comment #4 from Henri Verbeet hverbeet@gmail.com 2011-11-01 06:05:08 CDT --- Created attachment 37236 --> http://bugs.winehq.org/attachment.cgi?id=37236 patch
This is probably invalid. What seems to happen is that the application pushes crap (including -nan) onto the FPU stack, which then results in FPU stack overflows in the implicit matrix multiplication in glOrtho(). The end result is a projection matrix with -nan's in it. When compiled with -O2, the matrix multiplication in (gdi32) CombineTransform() ends up clearing enough of the FPU stack for glOrtho() to work. This does result in transformation matrices with -nan in them, but apparently this has no negative effects. The attached patch avoids the matrix multiplication in set_blit_dimension(), but doesn't change the fact that the application is essentially broken.