Forráskód Böngészése

unit conversion is only applied in root node.

Jihoon Lee 12 éve
szülő
commit
6e5a02427f
1 módosított fájl, 7 hozzáadás és 3 törlés
  1. 7 3
      examples/js/loaders/ColladaLoader.js

+ 7 - 3
examples/js/loaders/ColladaLoader.js

@@ -151,6 +151,10 @@ THREE.ColladaLoader = function () {
 
 
 		}
 		}
 
 
+    // unit conversion
+    scene.position.multiplyScalar(colladaUnit);
+    scene.scale.multiplyScalar(colladaUnit);
+
 		createAnimations();
 		createAnimations();
 
 
 		var result = {
 		var result = {
@@ -846,9 +850,9 @@ THREE.ColladaLoader = function () {
 		obj.useQuaternion = true;
 		obj.useQuaternion = true;
 		obj.scale = props[ 2 ];
 		obj.scale = props[ 2 ];
 
 
-    // unit conversion
-    obj.position.multiplyScalar(colladaUnit);
-    obj.scale.multiplyScalar(colladaUnit);
+
+
+
 
 
 		if ( options.centerGeometry && obj.geometry ) {
 		if ( options.centerGeometry && obj.geometry ) {