Browse Source

Merge pull request #19931 from WestLangley/dev_rgba_format

WebGLCubeRenderTarget: default to RGBA format in .fromEquirectangularTexture()
Mr.doob 5 years ago
parent
commit
077688c919
1 changed files with 2 additions and 2 deletions
  1. 2 2
      src/renderers/WebGLCubeRenderTarget.js

+ 2 - 2
src/renderers/WebGLCubeRenderTarget.js

@@ -1,4 +1,4 @@
-import { BackSide, NoBlending } from '../constants.js';
+import { BackSide, NoBlending, RGBAFormat } from '../constants.js';
 import { Scene } from '../scenes/Scene.js';
 import { Mesh } from '../objects/Mesh.js';
 import { BoxBufferGeometry } from '../geometries/BoxGeometry.js';
@@ -34,7 +34,7 @@ WebGLCubeRenderTarget.prototype.isWebGLCubeRenderTarget = true;
 WebGLCubeRenderTarget.prototype.fromEquirectangularTexture = function ( renderer, texture ) {
 
 	this.texture.type = texture.type;
-	this.texture.format = texture.format;
+	this.texture.format = RGBAFormat; // see #18859
 	this.texture.encoding = texture.encoding;
 
 	this.texture.generateMipmaps = texture.generateMipmaps;