(07-29-2014, 02:08 PM)triad Wrote: Unfortunately it's not "exactly" playable due to a horrible graphics glitch (see attached). I get loosely similar behavior in other games as well - certain textures with similar effects, or similar effect from bloom shaders washing out large portions of the frame - but this is unusually bad. (Note that the cinematics and menu screen don't show this problem.)
I've made a partial breakthrough... the problem is somewhere in the logic of what WriteFog adds to the shader. If I disable that, things look MUCH better (and not just in this game).
Note that the 'disable fog' option does NOT help!
(08-31-2014, 08:56 AM)triad Wrote:(07-29-2014, 02:08 PM)triad Wrote: Unfortunately it's not "exactly" playable due to a horrible graphics glitch (see attached). I get loosely similar behavior in other games as well - certain textures with similar effects, or similar effect from bloom shaders washing out large portions of the frame - but this is unusually bad. (Note that the cinematics and menu screen don't show this problem.)
I've made a partial breakthrough... the problem is somewhere in the logic of what WriteFog adds to the shader. If I disable that, things look MUCH better (and not just in this game).
Note that the 'disable fog' option does NOT help!
Okay, I may be stuck...
Something is going bonkers at this line:
Code:
int ifog = iround(fog * 256.0);
If I change that to any reasonable value (0 - 255), things work reasonably. Otherwise it's busted. At a guess, 'fog' here is a non-finite number, which is somehow causing the GPU to go screwy when converting it to an int. (And calling clamp() doesn't help.) So the real question is, why is 'fog' a screwy number?