summaryrefslogtreecommitdiff
path: root/indra/newview
diff options
context:
space:
mode:
authorAndrey Kleshchev <andreykproductengine@lindenlab.com>2024-06-19 13:36:44 +0300
committerAndrey Kleshchev <117672381+akleshchev@users.noreply.github.com>2024-06-20 10:46:40 +0300
commit5c9d985b92ce059044cb15a0bdafa84dd3bd777f (patch)
treebabe808d1275e2f9c6cc803876a656e9fc41fbaf /indra/newview
parent5b13c53e3165fea359d0f1af9c2d10c931f893d5 (diff)
triage#59 Properly hide particles if 'friends only'
Diffstat (limited to 'indra/newview')
-rw-r--r--indra/newview/llvoavatar.cpp18
1 files changed, 15 insertions, 3 deletions
diff --git a/indra/newview/llvoavatar.cpp b/indra/newview/llvoavatar.cpp
index 035c02c804..b07d36832e 100644
--- a/indra/newview/llvoavatar.cpp
+++ b/indra/newview/llvoavatar.cpp
@@ -2587,7 +2587,7 @@ void LLVOAvatar::idleUpdate(LLAgent &agent, const F64 &time)
return;
}
- LLCachedControl<bool> friends_only(gSavedSettings, "RenderAvatarFriendsOnly", false);
+ static LLCachedControl<bool> friends_only(gSavedSettings, "RenderAvatarFriendsOnly", false);
if (friends_only()
&& !isUIAvatar()
&& !isControlAvatar()
@@ -8473,17 +8473,29 @@ bool LLVOAvatar::isTooComplex() const
bool LLVOAvatar::isTooSlow() const
{
+ if (mIsControlAvatar)
+ {
+ return mTooSlow;
+ }
+
static LLCachedControl<S32> compelxity_render_mode(gSavedSettings, "RenderAvatarComplexityMode");
- bool render_friend = (LLAvatarTracker::instance().isBuddy(getID()) && compelxity_render_mode > AV_RENDER_LIMIT_BY_COMPLEXITY);
+ static LLCachedControl<bool> friends_only(gSavedSettings, "RenderAvatarFriendsOnly", false);
+ bool is_friend = LLAvatarTracker::instance().isBuddy(getID());
+ bool render_friend = is_friend && compelxity_render_mode > AV_RENDER_LIMIT_BY_COMPLEXITY;
if (render_friend || mVisuallyMuteSetting == AV_ALWAYS_RENDER)
{
return false;
}
- else if (compelxity_render_mode == AV_RENDER_ONLY_SHOW_FRIENDS && !mIsControlAvatar)
+ else if (compelxity_render_mode == AV_RENDER_ONLY_SHOW_FRIENDS)
+ {
+ return true;
+ }
+ else if (!is_friend && friends_only())
{
return true;
}
+
return mTooSlow;
}