index of first body in the contact constraint
index of second body in the contact constraint
index of the contact in the global contact array, used to look up contact for writing back solved impulses
pool of 4 contact points, only the first numContactPoints entries are valid
combined friction coefficient, computed from both bodies' friction values. typical range: 0.0 (frictionless) to 1.0+ (high friction)
inverse inertia matrix of body A, used to compute angular impulse response. cached from body at constraint setup time
inverse mass matrix of body B, used to compute angular impulse response. cached from body at constraint setup time
inverse inertia scale for body A, applied during position constraint solving to override inertia
inverse inertia scale for body B, applied during position constraint solving to override inertia
inverse mass of body A (1/massA), 0 if body is static. cached from body at constraint setup time
inverse mass of body B (1/massB), 0 if body is static. cached from body at constraint setup time
normalized contact normal (points from A toward B), same for all 4 contact points in this manifold
number of active contact points (0-4), used to track how many of the pre-allocated contactPoints are valid
combined restitution coefficient, controls bounce behavior. typical range: 0.0 (no bounce) to 1.0+ (perfect bounce)
sort key for deterministic ordering
sub-shape ID of shape A
sub-shape ID of shape B
first tangent vector (perpendicular to normal), computed as: normalize(cross(normal, arbitrary_vector))
second tangent vector (perpendicular to normal and tangent1), computed as: cross(normal, tangent1)
Contact constraint for a body pair. Contains all contact points and shared constraint data.
One ContactConstraint per active collision pair per frame. Can have 1-4 contact points. All contact points share the same normal/tangent directions and material properties.