summaryrefslogtreecommitdiff
path: root/indra/newview/llviewerregion.cpp
diff options
context:
space:
mode:
authorXiaohong Bao <bao@lindenlab.com>2013-01-25 17:15:07 -0700
committerXiaohong Bao <bao@lindenlab.com>2013-01-25 17:15:07 -0700
commit5ee3071e85de80cd37cc95c51dee5c497957ff9f (patch)
tree57152dfc9f4e71013262727bad62d97e59b53365 /indra/newview/llviewerregion.cpp
parentd93fe6c4353a6501af2704408d2921181fea6b75 (diff)
parent3660f8b632d1288cefeeff66c3b62522b4bbacbc (diff)
Automated merge with ssh://hg.lindenlab.com/richard/viewer-interesting
Diffstat (limited to 'indra/newview/llviewerregion.cpp')
-rw-r--r--indra/newview/llviewerregion.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/indra/newview/llviewerregion.cpp b/indra/newview/llviewerregion.cpp
index 45d43bdf74..e5cb2a1b08 100644
--- a/indra/newview/llviewerregion.cpp
+++ b/indra/newview/llviewerregion.cpp
@@ -1724,13 +1724,13 @@ LLVOCacheEntry* LLViewerRegion::getCacheEntry(U32 local_id)
//estimate weight of cache missed object
F32 LLViewerRegion::calcObjectWeight(U32 flags)
{
- LLVector3 pos((F32)(flags & 0xff), (F32)((flags >> 8) & 0xff), (F32)((flags >> 16) & 0xff) * 16.f);
+ LLVector3 pos((F32)(flags & 0xff) + 0.5f, (F32)((flags >> 8) & 0xff) + 0.5f, (F32)((flags >> 16) & 0xff) * 16.f + 8.0f);
F32 rad = (F32)((flags >> 24) & 0xff);
pos += getOriginAgent();
pos -= LLViewerCamera::getInstance()->getOrigin();
- return rad * rad / pos.lengthSquared();
+ return 100.f * rad * rad / pos.lengthSquared();
}
void LLViewerRegion::addCacheMiss(U32 id, LLViewerRegion::eCacheMissType miss_type, F32 weight)