Subscribe to GameDev.net Direct to receive the latest updates and exclusive content.
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.
Posted 05 March 2011 - 02:04 PM
Posted 07 March 2011 - 06:05 AM
I found a possible mistake in Brian Mirtich's phd thesis, specifically his method for resolving rigid body collisions with friction.
I've written up the details and a fixed version of the collision response algorithm here:
http://www.euclidean...rianMirtich.pdf
I've also created a small C app demonstrating the simple "2D collisions with friction algorithm" at the bottom of the following page:
http://www.euclidean...tical/index.htm
I thought maybe someone on this forum might find it useful, my apologies if I've wasted everybodys time with this post.
I don't hang out on this forum (this is my first post) if you want to contact me you can do so by email (see the pdf for my address).
Posted 07 March 2011 - 06:42 AM
Posted 07 March 2011 - 07:57 AM
Thanks for the post
The method I describe/corrected is an impulse based method. The question is how you work out the impulse when friction is involved. The most common method I've seen is to calculate the impulse without friction lets call it J, then apply a tangential impulse of J times the coefficient of friction. However, this gives unrealistic looking simulations, and can increase the energy of the system, which even in game physics looks unacceptable.
The method I give for 3D collisions isn't particulary efficient (involves solving a differential equation numerically), but the method for 2D collisions is pretty quick it doesn't involve any loops just a series of checks to determine which case we lie in. It should be comparable to the speed of the naive approach in common use but gives much better looking results.
I thought people would be interested but so far you are the only person who's glanced at it.
Rahil
Posted 07 March 2011 - 10:09 AM
Posted 07 March 2011 - 11:48 AM
Sorry it seems it takes a while for the board or my browser to update the view counter on this post. For the past 2 days it read 0 views but it has suddenly shot up to 139.
I agree your method doesn't sound like it causes an increase in energy, though I'm not sure I completely understand it. My understanding is this:
1) find the impulse in the normal direction using "the standard" frictionless impulse equation and apply the impulse.
2) find the impulse in the tangent direction by imagining the object is colliding with an imaginary perpendicular surface (do you still use the coefficient of restitution in this impulse calculation?)
3)Scale the impulse by the coefficient of friction.
4)Check if the tangent impulse is larger then the normal impulse if so reduce the tangent impulse to the same size. Then apply the tangent impulse.
Is this your algorithm?
Posted 07 March 2011 - 12:22 PM
Posted 07 March 2011 - 06:18 PM
Using impulses instead of LCP or QP
Posted 08 March 2011 - 08:22 AM
Posted 08 March 2011 - 09:25 AM
So sequential impulse is an iterative method to solve the LCP, and the word "instead" is not applicable.
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.
GameDev.net™, the GameDev.net logo, and GDNet™ are trademarks of GameDev.net, LLC.