diff options
Diffstat (limited to 'indra/newview/llreflectionmap.cpp')
-rw-r--r-- | indra/newview/llreflectionmap.cpp | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/indra/newview/llreflectionmap.cpp b/indra/newview/llreflectionmap.cpp index ec54fa1165..a26445b4bc 100644 --- a/indra/newview/llreflectionmap.cpp +++ b/indra/newview/llreflectionmap.cpp @@ -167,7 +167,16 @@ void LLReflectionMap::autoAdjustOrigin() { mPriority = 1; mOrigin.load3(mViewerObject->getPositionAgent().mV); - mRadius = mViewerObject->getScale().mV[0]*0.5f; + + if (mViewerObject->getVolume() && ((LLVOVolume*)mViewerObject)->getReflectionProbeIsBox()) + { + LLVector3 s = mViewerObject->getScale().scaledVec(LLVector3(0.5f, 0.5f, 0.5f)); + mRadius = s.magVec(); + } + else + { + mRadius = mViewerObject->getScale().mV[0] * 0.5f; + } } } |