split impulse threshold sign

gjaegy
Posts: 178
Joined: Fri Apr 18, 2008 2:20 pm

split impulse threshold sign

Post by gjaegy »

Hi,

I was wondering whether m_splitImpulsePenetrationThreshold values should be positive or not.

By default it is initialized to -0.02.

But in the wiki (http://bulletphysics.org/mediawiki-1.5. ... SolverInfo), the example set it to 0.2.

I understand split impulse is applied when the objects penetration is greater than the threshold, but what sign is it ?

thanks,
Greg
User avatar
Erwin Coumans
Site Admin
Posts: 4221
Joined: Sun Jun 26, 2005 6:43 pm
Location: California, USA

Re: split impulse threshold sign

Post by Erwin Coumans »

It is best to choose a negative value, the wiki needs to be updated.

The idea is to use the regular mixed LCP and Baumgarte term for small penetrations, and only use split impulse (position correction that doesn't affect the resulting velocity) for deeper penetrations than this threshold.

Thanks,
Erwin
gjaegy
Posts: 178
Joined: Fri Apr 18, 2008 2:20 pm

Re: split impulse threshold sign

Post by gjaegy »

great, thanks for your answer Erwin !