Re[1]: Re[1]: [ODE] Negative penetration depths

Raul Aguaviva raul.aguaviva at powervr.com
Fri Sep 6 01:50:02 2002


hmmm, all should have to be fixed in 1 time step, why 2 time steps?

another solution is to make the integration step smaller, or inversely
proportional to the speed of the moving objects

-----Original Message-----
From: Thomas Harte [mailto:thomasharte@lycos.co.uk]
Sent: 05 September 2002 19:02
To: ode@q12.org
Subject: Re[1]: Re[1]: [ODE] Negative penetration depths


> Check the direction of movement of the ----- object and you'll know from
> where was that object coming from so you can push it in the opposite
> direction.
> 
> I hope this helps
> Raul

That was my original intention - using dBodyGetRelPointVel, but the
following was liable 
to happen :

- start state : main object is in a valid position
- after 1 time step : points on main object are penetrating a 2 sided
object. We know 
which side we should push to due to velocity, as you say
- after 2 time steps : main object is still penetrating 2 sided object. But
now the 
constraint has removed all velocity 'in the direction' of the 2 sided
object, and the error 
reduction parameter has actually added velocity 'away from' the 2 sided
object, meaning 
that the main object is now heading in the other direction. So a simple
velocity based 
solution is fooled.

This is presumably the oscillation problem referred to elsewhere?

A solution I tried was this :

if(object is non-penetrating)
 store to last valid velocity;
else
 make decisions based on last valid velocity;

But that doesn't work because while an object is penetrating one object, it
may run along 
a little and start penetrating another. In which case you have to start
thinking about 
storing last valid velocity per currently penetrated object. And I start
thinking that a 
solution involving backward stepping (since my simulation is only 1 to 8
islands, each of 
around five bodies, and one static environment) and possibly a binary search
for a more 
accurate penetration time is probably more cost effective.

-Thomas
______________________________________________________
Check out all the latest outrageous email attachments on the Outrageous
Email Chart! - http://viral.lycos.co.uk