File tree Expand file tree Collapse file tree 1 file changed +3
-4
lines changed Expand file tree Collapse file tree 1 file changed +3
-4
lines changed Original file line number Diff line number Diff line change @@ -54,8 +54,9 @@ AFRAME.registerComponent("cubemap", {
5454 transparent : true
5555 } ) . clone ( ) ;
5656
57- //https://github.com/mrdoob/three.js/wiki/Migration-Guide#145--146
58- //they changed the name of the uniform from tCube to envMap, this variable helps us keep track of the name across three js versions
57+ // Starting in Three.js v146, `envMap` changed to `tCube`.
58+ // This variable helps us keep track of the name across Three.js versions.
59+ // https://github.com/mrdoob/three.js/wiki/Migration-Guide#145--146
5960 this . envMapUniformName = this . material . uniforms [ "envMap" ] ? "envMap" : "tCube" ;
6061
6162
@@ -70,8 +71,6 @@ AFRAME.registerComponent("cubemap", {
7071
7172 // A dummy texture is needed (otherwise the shader will be invalid and spew
7273 // a million errors)
73-
74- // this.material.uniforms["envMap"].value = new THREE.Texture();
7574 this . material . uniforms [ this . envMapUniformName ] . value = new THREE . Texture ( ) ;
7675
7776 this . loader = new THREE . CubeTextureLoader ( ) ;
You can’t perform that action at this time.
0 commit comments