ShapeDesc
ShapeDesc = {
depth:number;height:number;kind:"box";width:number; } | {kind:"sphere";radius:number; } | {height:number;kind:"capsule";radius:number; } | {height:number;kind:"cylinder";radius:number; } | {height:number;kind:"cone";radius:number; } | {depth:number;kind:"plane";width:number; } | {kind:"mesh"; } | {kind:"model"; }
Defined in: packages/threeplay/src/plugins/shapes/types.ts:9
Describes the geometry of an object so other plugins (physics colliders,
debug) can reason about it without inspecting three.js geometry.
Sizes are in local units, before scale.
Union Members
Section titled “Union Members”Type Literal
Section titled “Type Literal”{ depth: number; height: number; kind: "box"; width: number; }
Type Literal
Section titled “Type Literal”{ kind: "sphere"; radius: number; }
Type Literal
Section titled “Type Literal”{ height: number; kind: "capsule"; radius: number; }
Type Literal
Section titled “Type Literal”{ height: number; kind: "cylinder"; radius: number; }
Type Literal
Section titled “Type Literal”{ height: number; kind: "cone"; radius: number; }
Type Literal
Section titled “Type Literal”{ depth: number; kind: "plane"; width: number; }
Type Literal
Section titled “Type Literal”{ kind: "mesh"; }
Arbitrary geometry: colliders use its bounding box, or a trimesh/hull on request.
Type Literal
Section titled “Type Literal”{ kind: "model"; }
A loaded model (assets plugin): same as mesh.