yskang

threejs-get-started-4

Apr 15th, 2020
478
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. // Add camera
  2. const camera = new THREE.PerspectiveCamera(
  3.                                      45,
  4.                                      window.innerWidth / window.innerHeight,
  5.                                      0.1,
  6.                                     100
  7. );
  8. camera.position.set( 10, 10, 10 );
  9. camera.lookAt( scene.position );
  10.  
  11. // Set up stage light
  12. const pointLight = new THREE.PointLight( 0xffffff );
  13. pointLight.position.set( 10, 10, -10 );
  14. scene.add( pointLight );
Advertisement
Add Comment
Please, Sign In to add comment