Browse Source

Merge pull request #7043 from tschw/dev

Simplified setting of material.program.
Mr.doob 10 years ago
parent
commit
0d9c08a8a4
1 changed files with 1 additions and 2 deletions
  1. 1 2
      src/renderers/WebGLRenderer.js

+ 1 - 2
src/renderers/WebGLRenderer.js

@@ -1269,8 +1269,6 @@ THREE.WebGLRenderer = function ( parameters ) {
 
 
 		}
 		}
 
 
-		material.program = properties.get( material ).program; // TODO: Do this at compile time
-
 	}
 	}
 
 
 	function projectObject( object ) {
 	function projectObject( object ) {
@@ -1614,6 +1612,7 @@ THREE.WebGLRenderer = function ( parameters ) {
 		}
 		}
 
 
 		materialProperties.program = program;
 		materialProperties.program = program;
+		material.program = program;
 
 
 		var attributes = program.getAttributes();
 		var attributes = program.getAttributes();