[GD-Windows] Strange float bug?
Brought to you by:
vexxed72
From: Brett B. <res...@ga...> - 2004-03-07 13:45:12
|
We have been tracking down the wierdest bug for several days. Our code = was crashing randomly and then we finally found a repeatable case where = an assert on an identity matrix when we check the orthonormalness of it = and we chanced upon a line of code that returned -nan that was simply x = =3D (1.0f - (a + b)). Anyway, I suddenly remembered a GDC talk about = Windows denormals, did a quick google and pasted a _controlfp( = _CW_DEFAULT, 0xfffff ) into our code and presto it now works. We make games for PS2 and GCN and are Windows amateurs, but I hate the = idea of not understanding what went wrong and how to properly handle = this. Has anybody ever encountered something like this before? Brett |