Cloth Simulation (XPBD)
How Niche Studio's XPBD cloth engine simulates drape, self-collision, and fit heatmaps on a parametric avatar.
What XPBD simulation does
Extended Position-Based Dynamics (XPBD) is a physics method that solves cloth constraints — stretch, bend, and shear — iteratively per frame in a way that stays stable at real-time frame rates, including with stiff fabrics and fine constraint meshes.
Niche Studio uses XPBD with per-fabric parameters (stretch stiffness, bend stiffness, density, friction) pulled from the assigned fabric so different materials behave differently under the same avatar and gravity: a stiff canvas holds its shape, a fluid viscose drapes and pools.
Self-collision and body collision
The simulation resolves collisions both against the avatar's body mesh and between cloth panels themselves — self-collision — so overlapping layers such as a jacket over a hoodie, or a wrap panel crossing itself, settle without interpenetrating.
Reading fit heatmaps
| Heatmap | Shows | Red usually means |
|---|---|---|
| Stretch | How far a fabric region is stretched beyond rest length | Fabric under tension — likely tight fit or short pattern |
| Pressure | Contact force between garment and body | Garment pressing into the body — reduce ease or adjust curve |
| Ease | Distance between garment surface and body | Very low ease (tight) or very high ease (loose), read alongside intent |