Explorar o código

Merge pull request #6300 from benaadams/patch-1

Pass texture in onUpdate
Ricardo Cabello %!s(int64=10) %!d(string=hai) anos
pai
achega
0fb2e1c466
Modificáronse 1 ficheiros con 2 adicións e 2 borrados
  1. 2 2
      src/renderers/WebGLRenderer.js

+ 2 - 2
src/renderers/WebGLRenderer.js

@@ -5589,7 +5589,7 @@ THREE.WebGLRenderer = function ( parameters ) {
 
 		texture.needsUpdate = false;
 
-		if ( texture.onUpdate ) texture.onUpdate();
+		if ( texture.onUpdate ) texture.onUpdate( texture );
 
 	};
 
@@ -5743,7 +5743,7 @@ THREE.WebGLRenderer = function ( parameters ) {
 
 				texture.needsUpdate = false;
 
-				if ( texture.onUpdate ) texture.onUpdate();
+				if ( texture.onUpdate ) texture.onUpdate( texture );
 
 			} else {