summaryrefslogtreecommitdiff
path: root/indra/newview/llperfstats.cpp
diff options
context:
space:
mode:
authorMaxim Nikolenko <maximnproductengine@lindenlab.com>2023-01-27 01:33:11 +0200
committerMaxim Nikolenko <maximnproductengine@lindenlab.com>2023-01-27 01:33:11 +0200
commitc43336d5ed211ab77f2dc12b6cb7442d7544a2f7 (patch)
treed16b662ed8310fc3748208715d51e2f94dd03fe1 /indra/newview/llperfstats.cpp
parent918efa36112a6cbaacb54a2eb9a43af859a09005 (diff)
SL-18930 Update Autotune panel
Diffstat (limited to 'indra/newview/llperfstats.cpp')
-rw-r--r--indra/newview/llperfstats.cpp17
1 files changed, 15 insertions, 2 deletions
diff --git a/indra/newview/llperfstats.cpp b/indra/newview/llperfstats.cpp
index cb5c674a32..959e0afbdf 100644
--- a/indra/newview/llperfstats.cpp
+++ b/indra/newview/llperfstats.cpp
@@ -123,8 +123,21 @@ namespace LLPerfStats
LLPerfStats::tunables.userTargetFPS = gSavedSettings.getU32("TargetFPS");
LLPerfStats::tunables.vsyncEnabled = gSavedSettings.getBOOL("RenderVSyncEnable");
LLPerfStats::tunables.userTargetReflections = gSavedSettings.getS32("UserTargetReflections");
- LLPerfStats::tunables.userAutoTuneEnabled = gSavedSettings.getBOOL("AutoTuneFPS");
- LLPerfStats::tunables.userAutoTuneLock = gSavedSettings.getBOOL("AutoTuneLock");
+
+ LLPerfStats::tunables.userAutoTuneLock = gSavedSettings.getBOOL("AutoTuneLock") && gSavedSettings.getU32("KeepAutoTuneLock");
+
+ if(gSavedSettings.getBOOL("AutoTuneLock") && !gSavedSettings.getU32("KeepAutoTuneLock"))
+ {
+ gSavedSettings.setBOOL("AutoTuneLock", FALSE);
+ }
+
+ LLPerfStats::tunables.userAutoTuneEnabled = LLPerfStats::tunables.userAutoTuneLock;
+
+ if (LLPerfStats::tunables.userAutoTuneEnabled && !gSavedSettings.getBOOL("AutoTuneFPS"))
+ {
+ gSavedSettings.setBOOL("AutoTuneFPS", TRUE);
+ }
+
// Note: The Max ART slider is logarithmic and thus we have an intermediate proxy value
updateRenderCostLimitFromSettings();
resetChanges();