瀏覽代碼

Issue #13180. FBXLoader PerspectiveCamera enhancement.

andts 7 年之前
父節點
當前提交
eb1e4bc60e
共有 1 個文件被更改,包括 3 次插入0 次删除
  1. 3 0
      examples/js/loaders/FBXLoader.js

+ 3 - 0
examples/js/loaders/FBXLoader.js

@@ -1525,10 +1525,13 @@
 
 							}
 
+							var focalLength = cameraAttribute.FocalLength ? cameraAttribute.FocalLength.value : null;
+
 							switch ( type ) {
 
 								case 0: // Perspective
 									model = new THREE.PerspectiveCamera( fov, aspect, nearClippingPlane, farClippingPlane );
+									if ( focalLength !== null ) model.setFocalLength( focalLength );
 									break;
 
 								case 1: // Orthographic