This code creates a camera, then creates a scene object, adds a bunch of random particles to the scene, creates a <canvas> renderer and adds its viewport in the document.body element.
This code creates a camera, then creates a scene object, adds a bunch of random particles in it, creates a <canvas> renderer and adds its viewport in the document.body element.
<script type="text/javascript">
...
...
@@ -46,14 +46,11 @@ This code creates a camera, then creates a scene object, adds a bunch of random
function init() {
camera = new THREE.Camera( 75, SCREEN_WIDTH / SCREEN_HEIGHT, 0.0001, 10000 );
camera = new THREE.Camera( 75, window.innerWidth / window.innerHeight, 0.0001, 10000 );