Browse Source

Update README.md

Align name of animation loop.
Michael Herzog 1 year ago
parent
commit
f1ba3c4fbe
1 changed files with 2 additions and 2 deletions
  1. 2 2
      README.md

+ 2 - 2
README.md

@@ -43,12 +43,12 @@ scene.add( mesh );
 
 
 const renderer = new THREE.WebGLRenderer( { antialias: true } );
 const renderer = new THREE.WebGLRenderer( { antialias: true } );
 renderer.setSize( width, height );
 renderer.setSize( width, height );
-renderer.setAnimationLoop( animation );
+renderer.setAnimationLoop( animate );
 document.body.appendChild( renderer.domElement );
 document.body.appendChild( renderer.domElement );
 
 
 // animation
 // animation
 
 
-function animation( time ) {
+function animate( time ) {
 
 
 	mesh.rotation.x = time / 2000;
 	mesh.rotation.x = time / 2000;
 	mesh.rotation.y = time / 1000;
 	mesh.rotation.y = time / 1000;