//...
// SCENE
const scene = new THREE.Scene();
// TEXTURES
const loader = new THREE.TextureLoader();
const mercuryTexture = loader.load("assets/mercury.jpg");
// MATERIALS
const mercuryMaterial = new THREE.MeshStandardMaterial({ map: mercuryTexture });
// MESHES
const geometry = new THREE.SphereGeometry(1, 32, 16);
const mercuryMesh = new THREE.Mesh(geometry, mercuryMaterial);
mercuryMesh.position.set(25, 0, 0);
mercuryMesh.scale.setScalar(0.8);
scene.add(mercuryMesh);
// LIGHTING
//...
view raw block5.js hosted with ❤ by GitHub