{
const {scene, camera, renderer} = setup(invalidation)
const front = Math.tan(Math.PI / 6)
const back = Math.cos(Math.PI / 6)
const vertices = [
0, 1, 0,
1, 0, front,
-1, 0, front,
0, 0, -back,
0, -1, 0,
]
const faces = [
2, 1, 0,
1, 3, 0,
3, 2, 0,
2, 4, 1,
1, 4, 3,
3, 4, 2,
]
const geometry = new THREE.PolyhedronGeometry(vertices, faces, 30, 0)
const material = new THREE.MeshNormalMaterial()
const mesh = new THREE.Mesh(geometry, material)
scene.add(mesh)
mesh.scale.set(0.5, 1, 0.5)
while (true) {
mesh.rotation.y += 0.01;
renderer.render(scene, camera);
yield renderer.domElement;
}
}