浏览代码

Remove cache from Array of Vectors uniforms

Fernando Serrano 6 年之前
父节点
当前提交
9b7de2df47
共有 1 个文件被更改,包括 0 次插入15 次删除
  1. 0 15
      src/renderers/webgl/WebGLUniforms.js

+ 0 - 15
src/renderers/webgl/WebGLUniforms.js

@@ -523,41 +523,26 @@ function setValue1iv( gl, v ) {
 
 
 function setValueV2a( gl, v ) {
 function setValueV2a( gl, v ) {
 
 
-	var cache = this.cache;
 	var data = flatten( v, this.size, 2 );
 	var data = flatten( v, this.size, 2 );
 
 
-	if ( arraysEqual( cache, data ) ) return;
-
 	gl.uniform2fv( this.addr, data );
 	gl.uniform2fv( this.addr, data );
 
 
-	this.updateCache( data );
-
 }
 }
 
 
 function setValueV3a( gl, v ) {
 function setValueV3a( gl, v ) {
 
 
-	var cache = this.cache;
 	var data = flatten( v, this.size, 3 );
 	var data = flatten( v, this.size, 3 );
 
 
-	if ( arraysEqual( cache, data ) ) return;
-
 	gl.uniform3fv( this.addr, data );
 	gl.uniform3fv( this.addr, data );
 
 
-	this.updateCache( data );
-
 }
 }
 
 
 function setValueV4a( gl, v ) {
 function setValueV4a( gl, v ) {
 
 
-	var cache = this.cache;
 	var data = flatten( v, this.size, 4 );
 	var data = flatten( v, this.size, 4 );
 
 
-	if ( arraysEqual( cache, data ) ) return;
-
 	gl.uniform4fv( this.addr, data );
 	gl.uniform4fv( this.addr, data );
 
 
-	this.updateCache( data );
-
 }
 }
 
 
 // Array of matrices (flat or from THREE clases)
 // Array of matrices (flat or from THREE clases)