diff options
author | Andrey Lihatskiy <alihatskiy@productengine.com> | 2020-05-04 23:36:10 +0300 |
---|---|---|
committer | Andrey Lihatskiy <alihatskiy@productengine.com> | 2020-05-04 23:36:10 +0300 |
commit | 6bd9fe423325a4166110ae944e3ba79482a6a937 (patch) | |
tree | 5dc36870d9209352885cc127c6ad4a2605b051ff /indra/newview/pipeline.cpp | |
parent | f2d7be71842de8158926e181833cae086fd9e8b7 (diff) | |
parent | 4a7fd0117a43dca9e30c58c6417ebdf6862561f6 (diff) |
Merge branch 'master' into DRTVWR-497
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 a730c5a75b..3014fa4a1e 100644 --- a/indra/newview/pipeline.cpp +++ b/indra/newview/pipeline.cpp @@ -8745,29 +8745,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; |