Browse Source

Merge pull request #15916 from Mugen87/dev24

WebGLRenderer: Fix computation of parameter in .setRenderTarget().
Mr.doob 6 years ago
parent
commit
aa6ed08f12
1 changed files with 1 additions and 1 deletions
  1. 1 1
      src/renderers/WebGLRenderer.js

+ 1 - 1
src/renderers/WebGLRenderer.js

@@ -2611,7 +2611,7 @@ function WebGLRenderer( parameters ) {
 		if ( isCube ) {
 		if ( isCube ) {
 
 
 			var textureProperties = properties.get( renderTarget.texture );
 			var textureProperties = properties.get( renderTarget.texture );
-			_gl.framebufferTexture2D( _gl.FRAMEBUFFER, _gl.COLOR_ATTACHMENT0, _gl.TEXTURE_CUBE_MAP_POSITIVE_X + activeCubeFace || 0, textureProperties.__webglTexture, activeMipMapLevel || 0 );
+			_gl.framebufferTexture2D( _gl.FRAMEBUFFER, _gl.COLOR_ATTACHMENT0, _gl.TEXTURE_CUBE_MAP_POSITIVE_X + ( activeCubeFace || 0 ), textureProperties.__webglTexture, activeMipMapLevel || 0 );
 
 
 		}
 		}