I noticed a very strange interference when using Ogre and Newton Game Dynamics together in one application. It seems as if the call to
Root::Initialize() changes the result of Newtons calculations.
I first noticed it wehn I tried to develop a server-client application where only the clients use ogre for graphical output.
When I started the simulation with the same initial state and applying
the same forces at the same times, using fixed timesteps, the
simulation outcome on all clients was the same, but different from the server.
I figured out that the simulation on the server and the clients get in sync if I do not initialize the graphical output on the client side or
if I just initialize Ogre until the call of Root:Initialize().
I then investigated further and now, I've got an single app that
intitalizes a newton scene, advances it a few steps and saves the final state to a file. If I initialize Ogre in this app at the beginning, I get a different file then without initilization. I can toggle the
outcome of the simulation by just commenting in and out this one
Root::Initialize() call. Pretty strange, huh?
I've already posted this problem on the Newton forum: http://physicsengine.com/forum/viewtopic.php?t=1009 , but since Julio is away for a few days, noone seems to have a clue there.
I have no real explanaition to this effect. Any ideas? Maybe Ogre's memory manager? Maybe Ogre switches some flags of the floating point unit when initializing itself, producing slightly different results in Newton's calculations afterwards? Maybe Newton has a problem somewhere? Maybe I missed something?
Any suggestion is welcome.
