[ODE] dWorldStepFast and bouncing bodies

Adam D. Moss adam at gimp.org
Wed Dec 3 19:05:39 MST 2003


Drealmer wrote:
> When I use dWorldStepFast1 instead of dWorldStep, the dynamic bodies (body + geom) are not bouncing on each other, but still
> bouncing on static geometry (geom without body) can someone explain me why, and what I can do about this ?
> 
> Here's how to reproduce the problem with the "boxstack" sample :
> 
> 1. line 85 : change to "contact[i].surface.bounce = 0.75;"
> 2. line 357 : change to "if (!pause) dWorldStepFast1 (world,0.05, 10);"
> 3. compile and run the program
> 4. hit "r" key to allow the object to be generated at the same place.
> 5. hit "s" to create a sphere, and see how it bounces on the ground plane.
> 6. hit "s" a second time, and see the new sphere not bouncing at all on the first one...
> 
> Changing line 357 back to using dWorldStep works perfectly.
> I also noticed that if the upper sphere is a lot smaller than the one under, it bounces even with dWorldStepFast1.

I haven't tried to reproduce this, but the last data point could
be the key.  I suspect that you may be seeing one of StepFast's main
weaknesses when two colliding bodies have greatly differing
masses.  The docs may have tips for avoiding this (IIRC a greater
number of microsteps helps, but 10 already seems fairly generous).

--Adam
-- 
Adam D. Moss   . ,,^^   adam at gimp.org   http://www.foxbox.org/   co:3
Consume Less, Live More


More information about the ODE mailing list