Explorar el Código

#7245: Added missing support for texture arrays

Marius Kintel hace 10 años
padre
commit
65933fe239
Se han modificado 1 ficheros con 5 adiciones y 1 borrados
  1. 5 1
      src/renderers/WebGLRenderer.js

+ 5 - 1
src/renderers/WebGLRenderer.js

@@ -2366,9 +2366,13 @@ THREE.WebGLRenderer = function ( parameters ) {
 
 							setCubeTexture( texture, textureUnit );
 
+						} else if ( texture instanceof THREE.WebGLRenderTarget ) {
+
+							_this.setTexture( texture.texture, textureUnit );
+
 						} else if ( texture instanceof THREE.WebGLRenderTargetCube ) {
 
-							setCubeTextureDynamic( texture, textureUnit );
+							setCubeTextureDynamic( texture.texture, textureUnit );
 
 						} else {