提交 63e8599d 编写于 作者: M Mr.doob

Editor: Fixed cubemaps.

上级 ee77ce1f
......@@ -104,7 +104,7 @@ UI.CubeTexture = function ( position ) {
var scope = this;
this.texture = new THREE.Texture( [], new THREE.CubeReflectionMapping() );
this.texture = null;
this.dom = document.createElement( 'input' );
this.dom.type = 'file';
......@@ -124,7 +124,7 @@ UI.CubeTexture = function ( position ) {
var image = document.createElement( 'img' );
image.addEventListener( 'load', function( event ) {
scope.texture.image = [ this, this, this, this, this, this ];
scope.texture = new THREE.Texture( [ this, this, this, this, this, this ], new THREE.CubeReflectionMapping() )
scope.texture.needsUpdate = true;
if ( scope.onChangeCallback ) scope.onChangeCallback();
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册