1
0
Fork 1
mirror of https://github.com/TES3MP/openmw-tes3mp.git synced 2025-01-29 17:15:32 +00:00

CS: Make camera FOV change dynamically

This commit is contained in:
Miloslav Číž 2017-12-08 00:05:50 +01:00
parent 7d36dd68dc
commit cfdc6c788e

View file

@ -374,6 +374,13 @@ void SceneWidget::settingChanged (const CSMPrefs::Setting *setting)
{
mOrbitCamControl->setOrbitSpeedMultiplier(setting->toDouble());
}
else if (*setting=="Rendering/camera-fov")
{
mView->getCamera()->setProjectionMatrixAsPerspective(
setting->toDouble(),
static_cast<double>(width())/static_cast<double>(height()),
1.0f, 10000.0f);
}
}
void SceneWidget::selectNavigationMode (const std::string& mode)