shapeField.analytic3d

A true 3D solid (sphere, torus, knot…) from its baked distance function, rotated by the shape's live rotation so the swarm follows the surface as it turns.

shapeField.analytic3d(layout: RotatedFieldLayout, baked: ShapeField3): ShapeField3

Import sim from shaders/std and use sim.shapeFields.shapeField.analytic3d.

Parameters

NameTypeNotes
layoutRotatedFieldLayout
bakedShapeField3

Example

shapeField.analytic3d(setup3d.layout, setup3d.sdfFn as ShapeField3)

See also