function.createCubeObject
API > createCubeObject
Function: createCubeObject
createCubeObject(
material
?):RenderStateDynamicObject
Create a simple cube mesh object.
Parameters
Parameter | Type | Description |
---|---|---|
material ? | RenderStateDynamicMaterial | The material to use, or undefined for default material. |
Returns
Source
@novorender/web_app/geometry.ts:47
Example
const cube = createCubeObject();
view.modifyRenderState({ dynamic: { objects: [cube] } });