Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Rubix Cube

Public visualization

Viewing a saved revision (read-only)

06237dc93dcd44a9b996de07be2908f2

Rubix Cube

0 stars0🌍 Public
CCurran Kelleher
Last edited May 14, 2025
Created on May 14, 2025
Forked from 3D Cube of Spheres

This example renders a classic 3x3x3 Rubik’s Cube in Three.js using WebGL, with all standard color faces (white, yellow, red, orange, green, blue) applied to the outermost cubies. It uses three directional lights and ambient light to illuminate the scene, plus edge outlines to accentuate each cubelet. The user can rotate and zoom via OrbitControls, while an animation loop applies slow continuous rotation to the entire group. The code constructs the cube by positioning 26 small box meshes and assigns per-face materials based on their spatial position.

AI-generated description