diff options
author | Andrey Lihatskiy <alihatskiy@productengine.com> | 2020-05-04 23:39:37 +0300 |
---|---|---|
committer | Andrey Lihatskiy <alihatskiy@productengine.com> | 2020-05-04 23:39:37 +0300 |
commit | 1c82a80b2e48167ba718b6b79d51135cc7e7b371 (patch) | |
tree | cc8a5b339116a317d8329d34ee162d6a80ab013b /indra/newview/pipeline.cpp | |
parent | f4c7c8aff55d0cd8f044d5b7c8cddb2be750dde5 (diff) | |
parent | 4a7fd0117a43dca9e30c58c6417ebdf6862561f6 (diff) |
Merge branch 'master' into DRTVWR-486
Diffstat (limited to 'indra/newview/pipeline.cpp')
-rw-r--r-- | indra/newview/pipeline.cpp | 37 |
1 files changed, 16 insertions, 21 deletions
diff --git a/indra/newview/pipeline.cpp b/indra/newview/pipeline.cpp index f0ed303f66..01438bfb9f 100644 --- a/indra/newview/pipeline.cpp +++ b/indra/newview/pipeline.cpp @@ -8740,29 +8740,24 @@ void LLPipeline::renderDeferredLighting(LLRenderTarget* screen_target) } } - const LLViewerObject *vobj = drawablep->getVObj(); - if (vobj) - { - LLVOAvatar *av = vobj->getAvatar(); - if (av) - { - if (av->isTooComplex() || av->isInMuteList() || dist_vec(av->getPosition(), LLViewerCamera::getInstance()->getOrigin()) > RenderFarClip) - { - continue; - } - } - else - { - const LLViewerObject *root_obj = drawablep->getParent() ? drawablep->getParent()->getVObj() : vobj; - if (root_obj && dist_vec(root_obj->getPosition(), LLViewerCamera::getInstance()->getOrigin()) > RenderFarClip) - { - continue; - } - } - } + const LLViewerObject *vobj = drawablep->getVObj(); + if (vobj) + { + LLVOAvatar *av = vobj->getAvatar(); + if (av && (av->isTooComplex() || av->isInMuteList())) + { + continue; + } + } + + const LLVector3 position = drawablep->getPositionAgent(); + if (dist_vec(position, LLViewerCamera::getInstance()->getOrigin()) > RenderFarClip + volume->getLightRadius()) + { + continue; + } LLVector4a center; - center.load3(drawablep->getPositionAgent().mV); + center.load3(position.mV); const F32* c = center.getF32ptr(); F32 s = volume->getLightRadius()*1.5f; |