As I understand, before "world.GenerateContatcs()" is called, the position of the geometry in each "Flatland::Object", should be syncronized with the position of the body in that object, becaue the body has been moved in the previous frame by "world.QuickStep()".
I assume this syncronization is done with the "Object::Move()", correct ??? However, I couldn't find where this function is called (if its called at all).
So, can you tell me where this syncronization happens ( and if its done with "Object::Move()" )???
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Correct, it happens in Object::Move. ODE calls a callback function called "dGeomMove" whenever it needs to update the position of an object. At the top of flatland.cpp, you can see this line:
void dGeomMoved(dGeomID g) { g->Move(); }
That's where the sync occurs.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I am looking through the "simple demo" source code.
Every frame "app.Step(delta)" does this:
world.GenerateContacts(space);
world.QuickStep(delta);
As I understand, before "world.GenerateContatcs()" is called, the position of the geometry in each "Flatland::Object", should be syncronized with the position of the body in that object, becaue the body has been moved in the previous frame by "world.QuickStep()".
I assume this syncronization is done with the "Object::Move()", correct ??? However, I couldn't find where this function is called (if its called at all).
So, can you tell me where this syncronization happens ( and if its done with "Object::Move()" )???
Correct, it happens in Object::Move. ODE calls a callback function called "dGeomMove" whenever it needs to update the position of an object. At the top of flatland.cpp, you can see this line:
void dGeomMoved(dGeomID g) { g->Move(); }
That's where the sync occurs.