DriftCapture · function

propHulls

mesh decomposed into convex hulls the container can hold.

Explained in DriftCapture.

function propHulls(mesh: MeshData | CollisionSource, options?: DecomposeOptions): PropHulls
import { propHulls } from '@driftengine/capture';

Parameters

ParameterTypeDescription
meshMeshData | CollisionSource
options?DecomposeOptions

In depth

Asked for inside the caps rather than checked against them afterwards. A decomposition is the expensive part of baking a prop, and one that comes back with thirty-three hulls is one that has to be thrown away and asked for again — so the cap is what it is asked for. A hull that still arrives with more points than a record can hold is refused by name, because silently dropping its points changes the shape a game collides against without telling anybody.