Browse Source

Examples: Clean up

Mugen87 7 years ago
parent
commit
923c3490bc
1 changed files with 1 additions and 2 deletions
  1. 1 2
      examples/webgl_geometry_colors.html

+ 1 - 2
examples/webgl_geometry_colors.html

@@ -83,8 +83,7 @@
 				context.fillStyle = gradient;
 				context.fillRect( 0, 0, canvas.width, canvas.height );
 
-				var shadowTexture = new THREE.Texture( canvas );
-				shadowTexture.needsUpdate = true;
+				var shadowTexture = new THREE.CanvasTexture( canvas );
 
 				var shadowMaterial = new THREE.MeshBasicMaterial( { map: shadowTexture } );
 				var shadowGeo = new THREE.PlaneBufferGeometry( 300, 300, 1, 1 );