summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRunitaiLinden <davep@lindenlab.com>2023-06-13 14:45:12 -0500
committerRunitaiLinden <davep@lindenlab.com>2023-06-13 14:45:12 -0500
commitad956699c08620903150b9adfc2e8c34ccf5c390 (patch)
tree316d911092bed9405580e56b4160bf8dced2d6b6
parent0cb15b08b481de7b9d8d5967098ff76b8da3efdb (diff)
SL-19811 Update fallback probe every 2 seconds to smooth out water cloud updates.
-rw-r--r--indra/newview/app_settings/settings.xml2
-rw-r--r--indra/newview/llreflectionmapmanager.cpp16
2 files changed, 12 insertions, 6 deletions
diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml
index ecd63f4b21..ee14bb2b2f 100644
--- a/indra/newview/app_settings/settings.xml
+++ b/indra/newview/app_settings/settings.xml
@@ -10533,7 +10533,7 @@
<key>Type</key>
<string>F32</string>
<key>Value</key>
- <real>20.0</real>
+ <real>2.0</real>
</map>
<key>RenderReflectionProbeLevel</key>
<map>
diff --git a/indra/newview/llreflectionmapmanager.cpp b/indra/newview/llreflectionmapmanager.cpp
index 15d41c4161..e30aba3df7 100644
--- a/indra/newview/llreflectionmapmanager.cpp
+++ b/indra/newview/llreflectionmapmanager.cpp
@@ -323,11 +323,17 @@ void LLReflectionMapManager::update()
mRadiancePass = radiance_pass;
}
- static LLCachedControl<F32> sUpdatePeriod(gSavedSettings, "RenderDefaultProbeUpdatePeriod", 20.f);
- if (sLevel == 0 &&
- gFrameTimeSeconds - mDefaultProbe->mLastUpdateTime < sUpdatePeriod)
- { // when probes are disabled don't update the default probe more often than once every 20 seconds
- oldestProbe = nullptr;
+ static LLCachedControl<F32> sUpdatePeriod(gSavedSettings, "RenderDefaultProbeUpdatePeriod", 2.f);
+ if ((gFrameTimeSeconds - mDefaultProbe->mLastUpdateTime) < sUpdatePeriod)
+ {
+ if (sLevel == 0)
+ { // when probes are disabled don't update the default probe more often than the prescribed update period
+ oldestProbe = nullptr;
+ }
+ }
+ else if (sLevel > 0)
+ { // when probes are enabled don't update the default probe less often than the prescribed update period
+ oldestProbe = mDefaultProbe;
}
// switch to updating the next oldest probe