[ODE] Resetting/Zeroing/Clearing an object?

Anna-Beth Fox anna_beth_fox at yahoo.com.au
Sun Aug 6 22:55:13 MST 2006

I would like to reset a sphere created using ODE. So I used the following snippet:

   dMatrix3 r;
   dGeomSetRotation(the_ball.geom, r);
   dGeomSetPosition(the_ball.geom, 0.0f, 0.5f, 40.0f);
   dBodySetLinearVel(the_ball.body, 0.0f, 0.0f, 0.0f);
   dBodySetForce(the_ball.body, 0.0f, 0.0f, 0.0f);
   dBodySetTorque(the_ball.body, 0.0f, 0.0f, 0.0f);

Both the geom and body were created using ODE.

After I lunch my ball I would like to reset it so that it is returned to it's orginal position (at 0,0.5, 0) and has NO spin!!! Currently, when I reset my ball using the above code, the ball still "spins" (has continuous rotation).

What am I not clearing to stop the continuous rotation?



 Send instant messages to your online friends http://au.messenger.yahoo.com 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://q12.org/pipermail/ode/attachments/20060807/68a7f63d/attachment.htm

More information about the ODE mailing list