Box
Box
is a primitive object that creates a box.
Syntax
<Box />
Parameters
All objects share the same base parameters from ComponentObjectProps
.
Name | Type | Description |
---|---|---|
width | number | The width of the box. |
height | number | The height of the box. |
depth | number | The depth of the box. |
widthSegments | number | The number of segments along the width of the box. |
heightSegments | number | The number of segments along the height of the box. |
depthSegments | number | The number of segments along the depth of the box. |
radius | number | The radius of the box. |
bloom | boolean | Whether use bloom effect. |
color | ColorType | The base color. |
material | ObjectMaterialMix | The material. |
Example
<Box width={1} height={1} depth={1} position={[0, 2, 0]} />
Available on: Client Server