summaryrefslogtreecommitdiff
path: root/indra/newview/llagentcamera.cpp
diff options
context:
space:
mode:
authorAndreyL ProductEngine <alihatskiy@productengine.com>2020-01-06 20:28:37 +0200
committerAndreyL ProductEngine <alihatskiy@productengine.com>2020-01-06 20:28:37 +0200
commit2076f4af0fc946c3bd79754a1deefc495ee7edb9 (patch)
tree859f1a0a7a82a571dde9a26c738e59a862cd6c05 /indra/newview/llagentcamera.cpp
parent4c006e76e39a8b59dc6f9c890e5a27d38b5ece50 (diff)
parentd656d49a77eeb65ae537c954ea4009bc22da7b2b (diff)
Merged in viewer-release
Diffstat (limited to 'indra/newview/llagentcamera.cpp')
-rw-r--r--indra/newview/llagentcamera.cpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/indra/newview/llagentcamera.cpp b/indra/newview/llagentcamera.cpp
index 0b4b848014..8edb1a5f0b 100644
--- a/indra/newview/llagentcamera.cpp
+++ b/indra/newview/llagentcamera.cpp
@@ -807,6 +807,12 @@ void LLAgentCamera::setCameraZoomFraction(F32 fraction)
startCameraAnimation();
}
+F32 LLAgentCamera::getAgentHUDTargetZoom()
+{
+ static LLCachedControl<F32> hud_scale_factor(gSavedSettings, "HUDScaleFactor");
+ LLObjectSelectionHandle selection = LLSelectMgr::getInstance()->getSelection();
+ return (selection->getObjectCount() && selection->getSelectType() == SELECT_TYPE_HUD) ? hud_scale_factor*gAgentCamera.mHUDTargetZoom : hud_scale_factor;
+}
//-----------------------------------------------------------------------------
// cameraOrbitAround()
@@ -1449,7 +1455,7 @@ void LLAgentCamera::updateCamera()
attachment_iter != attachment->mAttachedObjects.end();
++attachment_iter)
{
- LLViewerObject *attached_object = (*attachment_iter);
+ LLViewerObject *attached_object = attachment_iter->get();
if (attached_object && !attached_object->isDead() && attached_object->mDrawable.notNull())
{
// clear any existing "early" movements of attachment