In geometry, an octahedron is a polyhedron with eight faces. A regular octahedron is a Platonic solid composed of eight equilateral triangles, four of which meet at each vertex.
WHS.Octahedron
creates Octahedron object by it's radius
and detail
.
const octahedron = new WHS.Octahedron({
geometry: {
radius: 2,
detail: 1
},
material: new THREE.MeshBasicMaterial({
color: 0xffffff
}),
position: [0, 100, 0]
});
octahedron.addTo(world);
Parameters
Geometry defaults
{
// ...
geometry: {
radius: 1, // Number
detail: 0 // Number
}
}
These defaults are additional, there are also defaults filled by
MeshComponent
, etc.
Instructions
{
// ...
geometry: ['radius', 'detail']
}
Updated almost 8 years ago