THREE.JS / FOUNDATIONS — GEOMETRY

A cube is a contract.

Keep the smallest official geometry example explicit: a BoxGeometry, a MeshBasicMaterial, an sRGB texture, and a renderer-owned animation loop.

Initializing cubeWebGL2
Preparing the native geometry and texture.
BACKEND
—
VERT / TRI
—
TEXTURE
—
ROTATION X / Y
—
SAMPLE
—
BUILDS
—
Cube controlsBOX / MESH / LOOP
BoxGeometry contract

The source example keeps the mesh intentionally small: six indexed faces, 24 position vertices, 36 index entries, color-managed texture input, and continuous rotation.

Derived from the official cube geometry example, pinned source, BoxGeometry, and CanvasTexture contracts. This bounded study does not claim whole-example fidelity.