Cone
A 3D cone with a pointed apex and circular base.
Usage
ts
import { createCone } from '@ripl/3d';
const cone = createCone({
radius: 1,
height: 2,
segments: 16,
fillStyle: '#cc4444',
});Properties
| Property | Type | Default | Description |
|---|---|---|---|
radius | number | — | Base radius |
height | number | — | Height from base to apex |
segments | number | 16 | Number of radial segments |
x | number | 0 | X position |
y | number | 0 | Y position |
z | number | 0 | Z position |
rotationX | number | 0 | Rotation around X axis (radians) |
rotationY | number | 0 | Rotation around Y axis (radians) |
rotationZ | number | 0 | Rotation around Z axis (radians) |