Documentation / Node reference / code nodes
code/SDFHexPrism
The distance to a hexagonal prism.
Sdf3d
Returns the signed distance from a sampled position to a regular hexagonal prism: a hexagon in the XY plane with its vertices along X and its flat sides facing Y, extruded along Z. It draws the same solid as a code/SDFHexagon2D extruded, and costs one expression per sample instead of a wrapped walk. The twin of geo/SDFHexPrism, for use inside a geo/SDFBuilder sub-network.
Parameters
| Name | Type | What it does |
|---|---|---|
| P | Vector3 | Position to sample the field at. Left unwired it reads the builder's own sample position. |
| t | Vector3 | Prism center. |
| radius | Float | Circumradius of the hexagon: center to a vertex, which is the reach along X. |
| height | Float | Full depth along Z: the prism spans half of it either side of the center. |
See also
- geo/SDFHexPrism
- code/SDFTriPrism
- code/SDFHexagon2D
- code/SDFBoolean
This page is generated from the engine, so it describes the release you can download. The same text is in the editor's Help panel next to the node itself.