From d205d5b139f9401f26446c6b43cf56cc5449a9d8 Mon Sep 17 00:00:00 2001 From: ChenX Date: Thu, 16 Feb 2023 17:09:29 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D:=E5=9C=A8=E8=AE=BE=E7=BD=AE?= =?UTF-8?q?=E9=80=8F=E8=A7=86=E7=9B=B8=E6=9C=BA=E7=9A=84=E8=A7=86=E9=87=8E?= =?UTF-8?q?=E8=A7=92=E5=BA=A6=E6=97=B6,=E4=BF=9D=E6=8C=81=E6=95=B0?= =?UTF-8?q?=E6=8D=AE=E6=AD=A3=E7=A1=AE=E6=80=A7,=E9=81=BF=E5=85=8D?= =?UTF-8?q?=E4=BF=9D=E5=AD=98=E7=9B=B8=E6=9C=BA=E5=90=8E=E7=9B=B8=E6=9C=BA?= =?UTF-8?q?=E5=81=8F=E7=A7=BB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../CameraControlButton/CameraState/CameraSetting.tsx | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/UI/Components/CameraControlButton/CameraState/CameraSetting.tsx b/src/UI/Components/CameraControlButton/CameraState/CameraSetting.tsx index bc51f3609..06cb241f5 100644 --- a/src/UI/Components/CameraControlButton/CameraState/CameraSetting.tsx +++ b/src/UI/Components/CameraControlButton/CameraState/CameraSetting.tsx @@ -14,7 +14,10 @@ export default class CameraSetting extends Component AlterCameraVision = (deg: number): void => { this.CameraSettingStore.cameraFov = deg; + let a1 = (Math.tan(MathUtils.degToRad(app.Viewer.CameraControl.Fov) / 2)); app.Viewer.CameraControl.Fov = deg; + let a2 = (Math.tan(MathUtils.degToRad(app.Viewer.CameraControl.Fov) / 2)); + app.Viewer.CameraControl.ViewHeight *= a2 / a1; app.Editor.UpdateScreen(); }; render()