Doc > Nodes > SOP > RoundedBox

Doc > Nodes > SOP > RoundedBox

Just like the Box, with rounded bevels.


no description


Name Type Description
size vector3 size of the box
divisions integer divisions count
bevel float bevel size
center vector3 center of the box

Edit code in JsFiddle , Codepen , view in a new tab or Open in the Editor

	// create a scene
const scene = new PolyScene();
const root = scene.root();

// create a box
const geo = root.createNode('geo');
const roundedBox = geo.createNode('roundedBox');

// add a light

// create a camera
const perspectiveCamera1 = root.createNode('perspectiveCamera');
perspectiveCamera1.p.t.set([5, 5, 5]);
// add orbitControls
const events1 = perspectiveCamera1.createNode('eventsNetwork');
const orbitsControls = events1.createNode('cameraOrbitControls');

// mount the viewer
const element = document.getElementById('app');