From f648f7df82fb9f7cc6b10c679313302ec267edfa Mon Sep 17 00:00:00 2001 From: anshk Date: Tue, 17 Mar 2026 17:40:31 +0530 Subject: [PATCH] feat: added directional light in vanilla --- three/main.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/three/main.js b/three/main.js index adc78cd..8d37d75 100644 --- a/three/main.js +++ b/three/main.js @@ -36,6 +36,9 @@ loader.load( const ambientLight = new THREE.AmbientLight( 0xcccccc, 0.8 ); scene.add( ambientLight ); +const directionalLight = new THREE.DirectionalLight(0xffffff, 1); +directionalLight.position.set(5, 10, 5); +scene.add(directionalLight); camera.position.z = 5;