diff --git a/build/three.js b/build/three.js index 1fe206c917a210..157b8a453ef2c4 100644 --- a/build/three.js +++ b/build/three.js @@ -15733,7 +15733,7 @@ _gl.framebufferRenderbuffer(_gl.FRAMEBUFFER, _gl.DEPTH_STENCIL_ATTACHMENT, _gl.RENDERBUFFER, renderbuffer); } else { // Use the first texture for MRT so far - const texture = renderTarget.isWebGLMultipleRenderTargets === true ? renderTarget.texture[0] : renderTarget.texture; + const texture = renderTarget.textures[0]; const glFormat = utils.convert(texture.format); const glType = utils.convert(texture.type); const glInternalFormat = getInternalFormat(texture.internalFormat, glFormat, glType); diff --git a/src/renderers/WebGLCubeRenderTarget.js b/src/renderers/WebGLCubeRenderTarget.js index 893e87c42d43a2..1e365f5c29e9f5 100644 --- a/src/renderers/WebGLCubeRenderTarget.js +++ b/src/renderers/WebGLCubeRenderTarget.js @@ -128,9 +128,9 @@ class WebGLCubeRenderTarget extends WebGLRenderTarget { const currentRenderTarget = renderer.getRenderTarget(); - for ( let f = 0; f < 6; f ++ ) { + for ( let i = 0; i < 6; i ++ ) { - renderer.setRenderTarget( this, f ); + renderer.setRenderTarget( this, i ); renderer.clear( color, depth, stencil ); diff --git a/src/textures/CubeTexture.js b/src/textures/CubeTexture.js index 391b4819a8a98c..cb182ba79d628a 100644 --- a/src/textures/CubeTexture.js +++ b/src/textures/CubeTexture.js @@ -19,7 +19,7 @@ class CubeTexture extends Texture { // three.js uses a right-handed coordinate system. So environment maps used in three.js appear to have px and nx swapped // and the flag _needsFlipEnvMap controls this conversion. The flip is not required (and thus _needsFlipEnvMap is set to false) - // when using a cube texture in WebGLCubeRenderTarget.textures. + // when using WebGLCubeRenderTarget.texture as a cube texture. this._needsFlipEnvMap = true;