sunag 7 jaren geleden
bovenliggende
commit
f57efb9f40
2 gewijzigde bestanden met toevoegingen van 3 en 3 verwijderingen
  1. 2 2
      examples/js/nodes/accessors/LightNode.js
  2. 1 1
      examples/webgl_materials_nodes.html

+ 2 - 2
examples/js/nodes/accessors/LightNode.js

@@ -22,13 +22,13 @@ LightNode.prototype.generate = function ( builder, output ) {
 
 	if ( builder.isCache( 'light' ) ) {
 
-		return builder.format( 'reflectedLight.directDiffuse', this.getType( builder ), output );
+		return builder.format( 'reflectedLight.directDiffuse', this.type, output );
 
 	} else {
 
 		console.warn( "THREE.LightNode is only compatible in \"light\" channel." );
 
-		return builder.format( 'vec3( 0.0 )', this.getType( builder ), output );
+		return builder.format( 'vec3( 0.0 )', this.type, output );
 
 	}
 

+ 1 - 1
examples/webgl_materials_nodes.html

@@ -1869,7 +1869,7 @@
 					// APPLY
 
 					mtl.color = color;
-					mtl.light = new THREE.LightNode();
+					mtl.light = posCelLight;
 					mtl.shininess = new THREE.FloatNode( 0 );
 
 					mtl.environment = lineColor;