Hi all. I am trying to write a collision detection & response routine for my 3d game. I am approximating my player's geometry with an ellipsoid, and I am detecting the swept ellipsoid's collision with convex shapes. If there is an intersection, I do bisection test to get the time of impact. However, now I want to get the contact normal, but I'm not sure how to do that. I tried using the last search direction as the separating vector, which turns out to be inaccurate. Most people suggest EPA, but I don't know if it works with quadric surfaces. Since one of the objects is an analytical shape on my case, is there any simpler way to get the contact normal or is EPA the way to go? Thanks a lot!
🎉 Celebrating 25 Years of GameDev.net! 🎉
Not many can claim 25 years on the Internet! Join us in celebrating this milestone. Learn more about our history, and thank you for being a part of our community!
Ellipsoid vs Convex shape GJK collision response
Don't implement EPA. Use a capsule for your player instead of an ellipse. Once you find the TOI, place the capsule at this location. Then use GJK without considering the capsule radius. This will give you the closest points bewteen the capsule's interior line segment, and the other convex volume. From here calculating resolution terms is trivial.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement