IT lexicon › Programming › Compound collider

Compound collider

Programming På svenska → Updated: 2026-10-27

A collision shape built from several simple primitives attached to the same rigid body, so a chair can be five boxes instead of one expensive mesh.

A moving body with a concave shape is a physics engine's headache: mesh colliders are expensive and often only work for static objects. The compound collider sidesteps the problem by approximating the shape with boxes, spheres and capsules, each convex and cheap to test. A hammer becomes a capsule for the handle and a box for the head.

To the engine the whole thing is still a single body: every part shares one velocity, and mass and centre of mass are computed from the pieces together. In Unity a compound collider appears automatically when several collider objects sit under the same Rigidbody; Box2D and Bullet have explicit compound shapes. When building them by hand gets too tedious, convex decomposition takes over and generates the pieces automatically.

← Back to the lexicon