瀏覽代碼

JSM: Rebuild files.

Mugen87 6 年之前
父節點
當前提交
40719eb42a

+ 1 - 1
examples/jsm/controls/TrackballControls.js

@@ -499,7 +499,7 @@ var TrackballControls = function ( object, domElement ) {
 	function touchstart( event ) {
 	function touchstart( event ) {
 
 
 		if ( _this.enabled === false ) return;
 		if ( _this.enabled === false ) return;
-		
+
 		event.preventDefault();
 		event.preventDefault();
 
 
 		switch ( event.touches.length ) {
 		switch ( event.touches.length ) {

+ 6 - 1
examples/jsm/exporters/GLTFExporter.js

@@ -1764,7 +1764,12 @@ GLTFExporter.prototype = {
 
 
 			} else {
 			} else {
 
 
-				object.updateMatrix();
+				if ( object.matrixAutoUpdate ) {
+
+					object.updateMatrix();
+
+				}
+
 				if ( ! equalArray( object.matrix.elements, [ 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1 ] ) ) {
 				if ( ! equalArray( object.matrix.elements, [ 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1 ] ) ) {
 
 
 					gltfNode.matrix = object.matrix.elements;
 					gltfNode.matrix = object.matrix.elements;

+ 4 - 2
examples/jsm/loaders/GLTFLoader.js

@@ -933,7 +933,8 @@ var GLTFLoader = ( function () {
 
 
 				for ( var i = 0, il = params.length; i < il; i ++ ) {
 				for ( var i = 0, il = params.length; i < il; i ++ ) {
 
 
-					target[ params[ i ] ] = source[ params[ i ] ];
+					var value = source[ params[ i ] ];
+					target[ params[ i ] ] = value.isColor ? value.clone() : value;
 
 
 				}
 				}
 
 
@@ -1391,7 +1392,7 @@ var GLTFLoader = ( function () {
 
 
 			if ( typeof gltfDef.extras === 'object' ) {
 			if ( typeof gltfDef.extras === 'object' ) {
 
 
-				object.userData = gltfDef.extras;
+				Object.assign( object.userData, gltfDef.extras );
 
 
 			} else {
 			} else {
 
 
@@ -3088,6 +3089,7 @@ var GLTFLoader = ( function () {
 
 
 			if ( nodeDef.name !== undefined ) {
 			if ( nodeDef.name !== undefined ) {
 
 
+				node.userData.name = nodeDef.name;
 				node.name = PropertyBinding.sanitizeNodeName( nodeDef.name );
 				node.name = PropertyBinding.sanitizeNodeName( nodeDef.name );
 
 
 			}
 			}

+ 3 - 2
examples/jsm/utils/ShadowMapViewer.js

@@ -63,7 +63,7 @@ var ShadowMapViewer = function ( light ) {
 	//HUD for shadow map
 	//HUD for shadow map
 	var shader = UnpackDepthRGBAShader;
 	var shader = UnpackDepthRGBAShader;
 
 
-	var uniforms = new UniformsUtils.clone( shader.uniforms );
+	var uniforms = UniformsUtils.clone( shader.uniforms );
 	var material = new ShaderMaterial( {
 	var material = new ShaderMaterial( {
 		uniforms: uniforms,
 		uniforms: uniforms,
 		vertexShader: shader.vertexShader,
 		vertexShader: shader.vertexShader,
@@ -109,7 +109,7 @@ var ShadowMapViewer = function ( light ) {
 	}
 	}
 
 
 
 
-	function resetPosition () {
+	function resetPosition() {
 
 
 		scope.position.set( scope.position.x, scope.position.y );
 		scope.position.set( scope.position.x, scope.position.y );
 
 
@@ -187,6 +187,7 @@ var ShadowMapViewer = function ( light ) {
 			 camera.updateProjectionMatrix();
 			 camera.updateProjectionMatrix();
 
 
 			 this.update();
 			 this.update();
+
 		}
 		}
 
 
 	};
 	};

+ 1 - 1
utils/modularize.js

@@ -24,7 +24,7 @@ var files = [
 	{ path: 'exporters/STLExporter.js', ignoreList: [] },
 	{ path: 'exporters/STLExporter.js', ignoreList: [] },
 	{ path: 'exporters/TypedGeometryExporter.js', ignoreList: [] },
 	{ path: 'exporters/TypedGeometryExporter.js', ignoreList: [] },
 
 
-	{ path: 'loaders/BVHLoader.js', ignoreList: [] },
+	{ path: 'loaders/BVHLoader.js', ignoreList: [ 'Bones' ] },
 	{ path: 'loaders/PCDLoader.js', ignoreList: [] },
 	{ path: 'loaders/PCDLoader.js', ignoreList: [] },
 	{ path: 'loaders/GLTFLoader.js', ignoreList: [ 'NoSide', 'Matrix2', 'DDSLoader' ] },
 	{ path: 'loaders/GLTFLoader.js', ignoreList: [ 'NoSide', 'Matrix2', 'DDSLoader' ] },
 	{ path: 'loaders/OBJLoader.js', ignoreList: [] },
 	{ path: 'loaders/OBJLoader.js', ignoreList: [] },