viewer#2705 Some sky parameters weren't updating

master
Andrey Kleshchev 2024-10-02 17:35:17 +03:00 committed by Andrey Kleshchev
parent 74fe406916
commit 3904a15c63
2 changed files with 10 additions and 1 deletions

View File

@ -1995,6 +1995,7 @@ F32 LLSettingsSky::getCloudShadow() const
void LLSettingsSky::setCloudShadow(F32 val)
{
mCloudShadow = val;
setDirtyFlag(true);
setLLSDDirty();
}
@ -2051,6 +2052,7 @@ F32 LLSettingsSky::getMaxY() const
void LLSettingsSky::setMaxY(F32 val)
{
mMaxY = val;
setDirtyFlag(true);
setLLSDDirty();
}
@ -2062,6 +2064,7 @@ LLQuaternion LLSettingsSky::getMoonRotation() const
void LLSettingsSky::setMoonRotation(const LLQuaternion &val)
{
mMoonRotation = val;
setDirtyFlag(true);
setLLSDDirty();
}
@ -2073,6 +2076,7 @@ F32 LLSettingsSky::getMoonScale() const
void LLSettingsSky::setMoonScale(F32 val)
{
mMoonScale = val;
setDirtyFlag(true);
setLLSDDirty();
}
@ -2095,6 +2099,7 @@ F32 LLSettingsSky::getMoonBrightness() const
void LLSettingsSky::setMoonBrightness(F32 brightness_factor)
{
mMoonBrightness = brightness_factor;
setDirtyFlag(true);
setLLSDDirty();
}
@ -2131,6 +2136,7 @@ LLColor3 LLSettingsSky::getSunlightColorClamped() const
void LLSettingsSky::setSunlightColor(const LLColor3 &val)
{
mSunlightColor = val;
setDirtyFlag(true);
setLLSDDirty();
}
@ -2142,6 +2148,7 @@ LLQuaternion LLSettingsSky::getSunRotation() const
void LLSettingsSky::setSunRotation(const LLQuaternion &val)
{
mSunRotation = val;
setDirtyFlag(true);
setLLSDDirty();
}
@ -2153,6 +2160,7 @@ F32 LLSettingsSky::getSunScale() const
void LLSettingsSky::setSunScale(F32 val)
{
mSunScale = val;
setDirtyFlag(true);
setLLSDDirty();
}

View File

@ -671,7 +671,8 @@ void LLSettingsVOSky::updateSettings()
// After some A/B comparison of relesae vs EEP, tweak to allow strength to fall below 2
// at night, for better match. (mSceneLightStrength is a divisor, so lower value means brighter
// local lights)
F32 sun_dynamic_range = llmax(gSavedSettings.getF32("RenderSunDynamicRange"), 0.0001f);
LLCachedControl<F32> sdr(gSavedSettings, "RenderSunDynamicRange", 1.f);
F32 sun_dynamic_range = llmax(sdr(), 0.0001f);
mSceneLightStrength = 2.0f * (0.75f + sun_dynamic_range * dp);
gSky.setSunAndMoonDirectionsCFR(sun_direction, moon_direction);