[ODE] Average Velocity feature and 'Disabling islands problem'

Christoph Beyer boernerb at web.de
Thu Nov 2 16:18:13 MST 2006


Hi!

http://sourceforge.net/tracker/index.php?func=detail&aid=1589606&group_id=24884&atid=382801

In this patch, there is a solution, how to integrate an additional 
feature to the AutoDisable System.
It is made with the revision 1118.
It adds this new functions to the API:

ODE_API dReal dWorldGetAutoDisableLinearAverageThreshold (dWorldID);

ODE_API void  dWorldSetAutoDisableLinearAverageThreshold (dWorldID, 
dReal linear_average_threshold);

ODE_API dReal dWorldGetAutoDisableAngularAverageThreshold (dWorldID);

ODE_API void dWorldSetAutoDisableAngularAverageThreshold (dWorldID, 
dReal angular_average_threshold);

ODE_API int dWorldGetAutoDisableAverageSize (dWorldID);

ODE_API void dWorldSetAutoDisableAverageSize (dWorldID, int average_size);

ODE_API dReal dBodyGetAutoDisableLinearAverageThreshold (dBodyID);

ODE_API void  dBodySetAutoDisableLinearAverageThreshold (dBodyID, dReal 
linear_average_threshold);

ODE_API dReal dBodyGetAutoDisableAngularAverageThreshold (dBodyID);

ODE_API void  dBodySetAutoDisableAngularAverageThreshold (dBodyID, dReal 
angular_average_threshold);

ODE_API int dBodyGetAutoDisableAverageSize (dBodyID);

ODE_API void dBodySetAutoDisableAverageSize (dBodyID, int average_size);

by default, the new feature is disabled.
for enabling, you should set the AverageSize!
If this feature is disabled ( AverageSize = 0), the new Autodisabling 
works like the old one.
If the feature is enabled, the average condition effect the idle state 
of a body.
Like the old system, the body has to be idle for "idle_steps" and 
"idle_time".
The body is not idle, if the linear/angular average velocity is too high.
The average velocities are calculated by adding the velocities from the 
last 'average_size' Steps together and divided by 'average_size'.

I gave it a try and it behaved like expected.
It is not realy the big goal, but it is usefull if one like to use the 
old and the new functions mixed.
You have to experiment with this.
I got a little bit better results by disabling jittering boxstacks.
The new API is compatible to the old one.

I hope my patch is created correctly,
it's my first time ;-)

But there is a big problem left, the problem of disabling whole islands!
I think, this is the main reason, because big boxstacks are so unstable 
and trembling.
Using a bigger soft_cfm value makes boxstacks more stable,
but you need a smaller timestep, because with a higher soft_cfm value, 
very small, heavy spheres are falling through walls!
Is this jittering a problem of ode's integrater or it is maybe a little 
bug in box/box collider?

Christoph



More information about the ODE mailing list