mirror of
https://github.com/HifiExperiments/overte.git
synced 2025-08-12 13:43:15 +02:00
Can use same clipping calc for non-Oculus
This commit is contained in:
parent
9c1d73747f
commit
eb438e9ccb
1 changed files with 2 additions and 4 deletions
|
@ -1177,10 +1177,8 @@ void MyAvatar::renderBody(ViewFrustum* renderFrustum, RenderArgs::RenderMode ren
|
|||
renderFrustum->setNearClip(DEFAULT_NEAR_CLIP);
|
||||
} else {
|
||||
float clipDistance = _skeletonModel.getHeadClipDistance();
|
||||
if (OculusManager::isConnected()) {
|
||||
clipDistance = glm::length(getEyePosition()
|
||||
+ camera->getOrientation() * glm::vec3(0.0f, 0.0f, -clipDistance) - cameraPos);
|
||||
}
|
||||
clipDistance = glm::length(getEyePosition()
|
||||
+ camera->getOrientation() * glm::vec3(0.0f, 0.0f, -clipDistance) - cameraPos);
|
||||
renderFrustum->setNearClip(clipDistance);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue