Browse Source

FramingBehavior will not force minZ if not required

David Catuhe 8 năm trước cách đây
mục cha
commit
fefbbcb430

Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 736 - 736
dist/preview release/babylon.d.ts


Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 1 - 1
dist/preview release/babylon.js


+ 3 - 1
dist/preview release/babylon.max.js

@@ -70163,7 +70163,9 @@ var BABYLON;
             }
             else if (this._mode === FramingBehavior.IgnoreBoundsSizeMode) {
                 radius = this._calculateLowerRadiusFromModelBoundingSphere(minimumWorld, maximumWorld);
-                this._attachedCamera.lowerRadiusLimit = this._attachedCamera.minZ;
+                if (this._attachedCamera.lowerRadiusLimit === null) {
+                    this._attachedCamera.lowerRadiusLimit = this._attachedCamera.minZ;
+                }
             }
             // transition to new radius
             if (!this._radiusTransition) {

Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 736 - 736
dist/preview release/babylon.module.d.ts


Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 38 - 38
dist/preview release/babylon.worker.js


Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 2375 - 2375
dist/preview release/customConfigurations/minimalGLTFViewer/babylon.d.ts


Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 1 - 1
dist/preview release/customConfigurations/minimalGLTFViewer/babylon.js


+ 3 - 1
dist/preview release/customConfigurations/minimalGLTFViewer/babylon.max.js

@@ -50136,7 +50136,9 @@ var BABYLON;
             }
             else if (this._mode === FramingBehavior.IgnoreBoundsSizeMode) {
                 radius = this._calculateLowerRadiusFromModelBoundingSphere(minimumWorld, maximumWorld);
-                this._attachedCamera.lowerRadiusLimit = this._attachedCamera.minZ;
+                if (this._attachedCamera.lowerRadiusLimit === null) {
+                    this._attachedCamera.lowerRadiusLimit = this._attachedCamera.minZ;
+                }
             }
             // transition to new radius
             if (!this._radiusTransition) {

Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 2375 - 2375
dist/preview release/customConfigurations/minimalGLTFViewer/babylon.module.d.ts


+ 3 - 1
src/Behaviors/Cameras/babylon.framingBehavior.ts

@@ -252,7 +252,9 @@ module BABYLON {
 				radius = position;
 			} else if (this._mode === FramingBehavior.IgnoreBoundsSizeMode) {
 				radius = this._calculateLowerRadiusFromModelBoundingSphere(minimumWorld, maximumWorld);
-				this._attachedCamera.lowerRadiusLimit = this._attachedCamera.minZ;
+				if (this._attachedCamera.lowerRadiusLimit === null) {
+					this._attachedCamera.lowerRadiusLimit = this._attachedCamera.minZ;
+				}
 			}
 
 			// transition to new radius