summaryrefslogtreecommitdiff
path: root/indra/newview/llagent.cpp
diff options
context:
space:
mode:
authorAdam Moss <moss@lindenlab.com>2009-06-20 09:17:56 +0000
committerAdam Moss <moss@lindenlab.com>2009-06-20 09:17:56 +0000
commit8ed056fde9fe5fc9755158013a5cb8be73066e2c (patch)
treed7f5f6de35c99ca645e48dc8817d908cc6d2f348 /indra/newview/llagent.cpp
parent351ebe9fcb76f3b99c2957004bb8493a904869ee (diff)
svn merge -r124872:124873
svn+ssh://svn.lindenlab.com/svn/linden/branches/viewer/viewer-1.23.threefour-merge-1a QAR-1592 Merge of changes between 1.23 RC2 and 1.23 Final to trunk
Diffstat (limited to 'indra/newview/llagent.cpp')
-rw-r--r--indra/newview/llagent.cpp15
1 files changed, 10 insertions, 5 deletions
diff --git a/indra/newview/llagent.cpp b/indra/newview/llagent.cpp
index 07503404dc..cc443d05c0 100644
--- a/indra/newview/llagent.cpp
+++ b/indra/newview/llagent.cpp
@@ -1319,14 +1319,19 @@ LLQuaternion LLAgent::getQuat() const
//-----------------------------------------------------------------------------
LLVector3 LLAgent::calcFocusOffset(LLViewerObject *object, LLVector3 original_focus_point, S32 x, S32 y)
{
- // calculate offset based on view direction
- BOOL is_avatar = object->isAvatar();
- // since the animation system allows the avatars facing and position to deviate from its nominal LLViewerObject/LLDrawable transform
- // calculate the focus-specific orientation for avatars based off the pelvis joint
- // NOTE: pelvis no longer good candidate, removed. DEV-30589
LLMatrix4 obj_matrix = object->getRenderMatrix();
LLQuaternion obj_rot = object->getRenderRotation();
LLVector3 obj_pos = object->getRenderPosition();
+
+ BOOL is_avatar = object->isAvatar();
+ // if is avatar - don't do any funk heuristics to position the focal point
+ // see DEV-30589
+ if (is_avatar)
+ {
+ return original_focus_point - obj_pos;
+ }
+
+
LLQuaternion inv_obj_rot = ~obj_rot; // get inverse of rotation
LLVector3 object_extents = object->getScale();
// make sure they object extents are non-zero