Convex / Convex collisions not generating enough contact points.

Issue #56 new
Bram Stolk created an issue

When I place two convex shapes on top of each other, so that the top one rests on the bottom one, then the collider generates only one contact point. One contact point is not enough to resolve the collision in a stable way.

The contact point will jump around, from corner to corner, causing an unstable wobble in the bodies.

This video demonstrates the behaviour. Note: that in the video, I single-step through the sim so that frame-by-frame changes are visible. (Contact position and depth are shown as yellow arrows.)

https://youtu.be/H7txuoUwxy0

This is with libccd convex/convex collider.

To fix this, the collider should generate a contact point for each of the vertices pushed into the shape. Additionally, it should generate contacts on edges as well, if one shape is resting halfway over the top of the other.

Comments (1)

  1. Bram Stolk reporter

    Looking at the libccd sources, this seems to be a limitation in libccd. The API for libccd collision tests will generate either 0 or 1 contact point+dir.

  2. Log in to comment