mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-02-04 03:40:14 +00:00
Merge branch 'dont-look-back-in-anger-or-look-backwards-at-all-really' into 'master'
Validate near and far clip distances See merge request OpenMW/openmw!2311
This commit is contained in:
commit
510eac3fb4
@ -1276,6 +1276,11 @@ namespace MWRender
|
||||
|
||||
void RenderingManager::updateProjectionMatrix()
|
||||
{
|
||||
if (mNearClip < 0.0f)
|
||||
throw std::runtime_error("Near clip is less than zero");
|
||||
if (mViewDistance < mNearClip)
|
||||
throw std::runtime_error("Viewing distance is less than near clip");
|
||||
|
||||
double width = Settings::Manager::getInt("resolution x", "Video");
|
||||
double height = Settings::Manager::getInt("resolution y", "Video");
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user