mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
#279 Fixed paralell projection nearplane bug introduced by 8098578545
This commit is contained in:
parent
a83e797e63
commit
ca6e650a72
@ -407,14 +407,15 @@ void caf::Viewer::optimizeClippingPlanes()
|
||||
}
|
||||
#endif
|
||||
|
||||
// TODO: Investigate why this is needed on Linux
|
||||
// When loading grid files on Linux, the nearPlaneDist results in 0 at this point
|
||||
nearPlaneDist = CVF_MAX(m_minNearPlaneDistance, nearPlaneDist);
|
||||
|
||||
if (farPlaneDist <= nearPlaneDist) farPlaneDist = nearPlaneDist + 1.0;
|
||||
|
||||
if (m_mainCamera->projection() == cvf::Camera::PERSPECTIVE)
|
||||
{
|
||||
// TODO: Investigate why this is needed on Linux
|
||||
// When loading grid files on Linux, the nearPlaneDist results in 0 at this point
|
||||
nearPlaneDist = CVF_MAX(m_minNearPlaneDistance, nearPlaneDist);
|
||||
|
||||
m_mainCamera->setProjectionAsPerspective(m_cameraFieldOfViewYDeg, nearPlaneDist, farPlaneDist);
|
||||
}
|
||||
else
|
||||
|
Loading…
Reference in New Issue
Block a user