In geometry, a tetrahedron is a polyhedron composed of four triangular faces, six straight edges, and four vertex corners. The tetrahedron is the simplest of all the ordinary convex polyhedra and the only one that has fewer than 5 faces.
WHS.Tetrahedron
creates Tetrahedron object by it's radius
and detail
.
const tetrahedron = new WHS.Tetrahedron({
geometry: {
radius: 2,
detail: 1
},
material: new THREE.MeshBasicMaterial({
color: 0xffffff
}),
position: {
x: 0,
y: 100,
z: 0
}
});
tetrahedron.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