Capítulo 30 de 859

Chapter 30: DodecahedronGeometry

Core Idea

A geometry class for representing a dodecahedron.

Key Concepts

  • parameters : Object: Holds the constructor parameters that have been used to generate the geometry. Any modification after instantiation does not change the geo…

Code Examples

const geometry = new THREE.DodecahedronGeometry();
const material = new THREE.MeshBasicMaterial( { color: 0xffff00 } );
const dodecahedron = new THREE.Mesh( geometry, material );
scene.add( dodecahedron );
  • What it demonstrates: Typical usage of DodecahedronGeometry.

Reference Tables

Constructor

Signature
new DodecahedronGeometry( radius : number, detail : number )

Properties

PropertyDescription
.parameters : ObjectHolds the constructor parameters that have been used to generate the geometry. Any modification after instantiation does not change the geometry.

Key Takeaways

  1. DodecahedronGeometry extends: EventDispatcher → BufferGeometry → PolyhedronGeometry
  2. Most relevant properties: parameters.

Connects To