Refactor camera change flow

This commit is contained in:
Withalion 2025-02-04 13:29:46 +01:00 committed by Martin Dobias
parent b3f105c782
commit 1e9e6677c9

View File

@ -188,10 +188,8 @@ void QgsCameraController::setViewFromTop( float worldX, float worldY, float dist
camPose.setHeadingAngle( yaw ); camPose.setHeadingAngle( yaw );
// we force the updateCameraNearFarPlanes() in Qgs3DMapScene to properly set the planes // we force the updateCameraNearFarPlanes() in Qgs3DMapScene to properly set the planes
// by making sure the cameraPose is never the same, which will emit cameraChanged() mCameraPose = camPose;
mCameraPose.setDistanceFromCenterPoint( camPose.distanceFromCenterPoint() + 1 ); updateCameraFromPose();
setCameraPose( camPose );
} }
QgsVector3D QgsCameraController::lookingAtPoint() const QgsVector3D QgsCameraController::lookingAtPoint() const