summaryrefslogtreecommitdiff
path: root/indra/newview
diff options
context:
space:
mode:
authorprep linden <prep@lindenlab.com>2011-01-27 17:13:08 -0500
committerprep linden <prep@lindenlab.com>2011-01-27 17:13:08 -0500
commit2e8640c3b084d00b3fa5de93b75ccaf25f2126a6 (patch)
tree0c3180c68b1d7f5bf32ab2d8233d9dcfe5206670 /indra/newview
parent1b97777f1ac5505be698837d8c94a4f5ff3af786 (diff)
Optimization so that updateRiggedAttachments is not called every frame - still a WIP.
Diffstat (limited to 'indra/newview')
-rw-r--r--indra/newview/llvoavatar.cpp6
-rw-r--r--indra/newview/llvoavatar.h1
-rw-r--r--indra/newview/llvoavatarself.cpp2
3 files changed, 7 insertions, 2 deletions
diff --git a/indra/newview/llvoavatar.cpp b/indra/newview/llvoavatar.cpp
index 55c5c85c21..4a6d303cdd 100644
--- a/indra/newview/llvoavatar.cpp
+++ b/indra/newview/llvoavatar.cpp
@@ -8163,12 +8163,16 @@ BOOL LLVOAvatar::updateLOD()
mNeedsSkin = TRUE;
mDrawable->clearState(LLDrawable::REBUILD_GEOMETRY);
}
- rebuildRiggedAttachments();
updateVisibility();
return res;
}
+void LLVOAvatar::updateLODRiggedAttachments( void )
+{
+ updateLOD();
+ rebuildRiggedAttachments();
+}
U32 LLVOAvatar::getPartitionType() const
{
// Avatars merely exist as drawables in the bridge partition
diff --git a/indra/newview/llvoavatar.h b/indra/newview/llvoavatar.h
index 7ef35178ca..99d0ed76e5 100644
--- a/indra/newview/llvoavatar.h
+++ b/indra/newview/llvoavatar.h
@@ -122,6 +122,7 @@ public:
virtual BOOL idleUpdate(LLAgent &agent, LLWorld &world, const F64 &time);
virtual BOOL updateLOD();
BOOL updateJointLODs();
+ void updateLODRiggedAttachments( void );
virtual BOOL isActive() const; // Whether this object needs to do an idleUpdate.
virtual void updateTextures();
virtual S32 setTETexture(const U8 te, const LLUUID& uuid); // If setting a baked texture, need to request it from a non-local sim.
diff --git a/indra/newview/llvoavatarself.cpp b/indra/newview/llvoavatarself.cpp
index 1ba4f9ce2d..d27d7be21b 100644
--- a/indra/newview/llvoavatarself.cpp
+++ b/indra/newview/llvoavatarself.cpp
@@ -1139,7 +1139,7 @@ const LLViewerJointAttachment *LLVOAvatarSelf::attachObject(LLViewerObject *view
LLAppearanceMgr::instance().registerAttachment(attachment_id);
// Clear any pending requests once the attachment arrives.
removeAttachmentRequest(attachment_id);
- updateLOD();
+ updateLODRiggedAttacmhments();
}
return attachment;