summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--indra/newview/app_settings/settings.xml2
-rw-r--r--indra/newview/llvovolume.cpp13
2 files changed, 13 insertions, 2 deletions
diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml
index c3d7d67c86..f1d0901a81 100644
--- a/indra/newview/app_settings/settings.xml
+++ b/indra/newview/app_settings/settings.xml
@@ -10227,7 +10227,7 @@
<key>Type</key>
<string>F32</string>
<key>Value</key>
- <real>7.5</real>
+ <real>6.5</real>
</map>
<key>RenderWater</key>
<map>
diff --git a/indra/newview/llvovolume.cpp b/indra/newview/llvovolume.cpp
index 5fc571bf1d..1112b7dee6 100644
--- a/indra/newview/llvovolume.cpp
+++ b/indra/newview/llvovolume.cpp
@@ -1257,7 +1257,18 @@ BOOL LLVOVolume::calcLOD()
lod_factor *= LLVOVolume::sRiggedFactorMultiplier;
distance = avatar->mDrawable->mDistanceWRTCamera;
F32 avatar_radius = avatar->getBinRadius();
- F32 object_radius = getVolume() ? getVolume()->mLODScaleBias.scaledVec(getScale()).length() : getScale().length();
+ F32 object_radius;
+ if (mDrawable.notNull() && !mDrawable->isDead())
+ {
+ const LLVector4a* ext = mDrawable->getSpatialExtents();
+ LLVector4a diff;
+ diff.setSub(ext[1], ext[0]);
+ object_radius = diff.getLength3().getF32();
+ }
+ else
+ {
+ object_radius = getVolume() ? getVolume()->mLODScaleBias.scaledVec(getScale()).length() : getScale().length();
+ }
radius = object_radius * LLVOVolume::sRiggedFactorMultiplier;
radius = llmin(radius, avatar_radius);
}