Skip to content

Commit 97826b5

Browse files
committed
viewer#3169 Legacy settings should no longer be automatically converted
1 parent 5f9fe87 commit 97826b5

File tree

8 files changed

+14
-10
lines changed

8 files changed

+14
-10
lines changed

indra/newview/app_settings/settings.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9185,7 +9185,7 @@
91859185
<key>Type</key>
91869186
<string>Boolean</string>
91879187
<key>Value</key>
9188-
<integer>1</integer>
9188+
<integer>0</integer>
91899189
</map>
91909190
<key>RenderSkyAutoAdjustAmbientScale</key>
91919191
<map>

indra/newview/llfloatereditextdaycycle.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1712,6 +1712,7 @@ void LLFloaterEditExtDayCycle::onPickerCommitSetting(LLUUID item_id, S32 track)
17121712

17131713
void LLFloaterEditExtDayCycle::showHDRNotification(const LLSettingsDay::ptr_t &pday)
17141714
{
1715+
static LLCachedControl<bool> should_auto_adjust(gSavedSettings, "RenderSkyAutoAdjustLegacy", false);
17151716
for (U32 i = LLSettingsDay::TRACK_GROUND_LEVEL; i <= LLSettingsDay::TRACK_MAX; i++)
17161717
{
17171718
LLSettingsDay::CycleTrack_t &day_track = pday->getCycleTrack(i);
@@ -1722,7 +1723,8 @@ void LLFloaterEditExtDayCycle::showHDRNotification(const LLSettingsDay::ptr_t &p
17221723
while (iter != end)
17231724
{
17241725
LLSettingsSky::ptr_t sky = std::static_pointer_cast<LLSettingsSky>(iter->second);
1725-
if (sky
1726+
if (should_auto_adjust()
1727+
&& sky
17261728
&& sky->canAutoAdjust()
17271729
&& sky->getReflectionProbeAmbiance(true) != 0.f)
17281730
{

indra/newview/llfloaterenvironmentadjust.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -178,7 +178,7 @@ void LLFloaterEnvironmentAdjust::refresh()
178178
getChild<LLTextureCtrl>(FIELD_SKY_CLOUD_MAP)->setValue(mLiveSky->getCloudNoiseTextureId());
179179
getChild<LLTextureCtrl>(FIELD_WATER_NORMAL_MAP)->setValue(mLiveWater->getNormalMapID());
180180

181-
static LLCachedControl<bool> should_auto_adjust(gSavedSettings, "RenderSkyAutoAdjustLegacy", true);
181+
static LLCachedControl<bool> should_auto_adjust(gSavedSettings, "RenderSkyAutoAdjustLegacy", false);
182182
getChild<LLUICtrl>(FIELD_REFLECTION_PROBE_AMBIANCE)->setValue(mLiveSky->getReflectionProbeAmbiance(should_auto_adjust));
183183

184184
LLColor3 glow(mLiveSky->getGlow());
@@ -494,7 +494,7 @@ void LLFloaterEnvironmentAdjust::updateGammaLabel()
494494
{
495495
if (!mLiveSky) return;
496496

497-
static LLCachedControl<bool> should_auto_adjust(gSavedSettings, "RenderSkyAutoAdjustLegacy", true);
497+
static LLCachedControl<bool> should_auto_adjust(gSavedSettings, "RenderSkyAutoAdjustLegacy", false);
498498
F32 ambiance = mLiveSky->getReflectionProbeAmbiance(should_auto_adjust);
499499
if (ambiance != 0.f)
500500
{

indra/newview/llfloaterfixedenvironment.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -182,8 +182,10 @@ void LLFloaterFixedEnvironment::setEditSettingsAndUpdate(const LLSettingsBase::p
182182
LLEnvironment::instance().updateEnvironment(LLEnvironment::TRANSITION_INSTANT);
183183

184184
// teach user about HDR settings
185+
static LLCachedControl<bool> should_auto_adjust(gSavedSettings, "RenderSkyAutoAdjustLegacy", false);
185186
if (mSettings
186187
&& mSettings->getSettingsType() == "sky"
188+
&& should_auto_adjust()
187189
&& ((LLSettingsSky*)mSettings.get())->canAutoAdjust()
188190
&& ((LLSettingsSky*)mSettings.get())->getReflectionProbeAmbiance(true) != 0.f)
189191
{

indra/newview/llpaneleditsky.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -209,7 +209,7 @@ void LLPanelSettingsSkyAtmosTab::refresh()
209209
F32 droplet_radius = mSkySettings->getSkyDropletRadius();
210210
F32 ice_level = mSkySettings->getSkyIceLevel();
211211

212-
static LLCachedControl<bool> should_auto_adjust(gSavedSettings, "RenderSkyAutoAdjustLegacy", true);
212+
static LLCachedControl<bool> should_auto_adjust(gSavedSettings, "RenderSkyAutoAdjustLegacy", false);
213213
F32 rp_ambiance = mSkySettings->getReflectionProbeAmbiance(should_auto_adjust);
214214

215215
getChild<LLUICtrl>(FIELD_SKY_DENSITY_MOISTURE_LEVEL)->setValue(moisture_level);

indra/newview/llreflectionmapmanager.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1070,7 +1070,7 @@ void LLReflectionMapManager::updateUniforms()
10701070
LLEnvironment& environment = LLEnvironment::instance();
10711071
LLSettingsSky::ptr_t psky = environment.getCurrentSky();
10721072

1073-
static LLCachedControl<bool> should_auto_adjust(gSavedSettings, "RenderSkyAutoAdjustLegacy", true);
1073+
static LLCachedControl<bool> should_auto_adjust(gSavedSettings, "RenderSkyAutoAdjustLegacy", false);
10741074
F32 minimum_ambiance = psky->getReflectionProbeAmbiance(should_auto_adjust);
10751075

10761076
bool is_ambiance_pass = gCubeSnapshot && !isRadiancePass();

indra/newview/llsettingsvo.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -795,7 +795,7 @@ void LLSettingsVOSky::applySpecial(void *ptarget, bool force)
795795
F32 g = getGamma();
796796

797797
static LLCachedControl<bool> hdr(gSavedSettings, "RenderHDREnabled");
798-
static LLCachedControl<bool> should_auto_adjust(gSavedSettings, "RenderSkyAutoAdjustLegacy", true);
798+
static LLCachedControl<bool> should_auto_adjust(gSavedSettings, "RenderSkyAutoAdjustLegacy", false);
799799
static LLCachedControl<F32> auto_adjust_ambient_scale(gSavedSettings, "RenderSkyAutoAdjustAmbientScale", 0.75f);
800800
static LLCachedControl<F32> auto_adjust_hdr_scale(gSavedSettings, "RenderSkyAutoAdjustHDRScale", 2.f);
801801
static LLCachedControl<F32> auto_adjust_blue_horizon_scale(gSavedSettings, "RenderSkyAutoAdjustBlueHorizonScale", 1.f);

indra/newview/pipeline.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7142,7 +7142,7 @@ void LLPipeline::tonemap(LLRenderTarget* src, LLRenderTarget* dst)
71427142

71437143
// Apply gamma correction to the frame here.
71447144

7145-
static LLCachedControl<bool> should_auto_adjust(gSavedSettings, "RenderSkyAutoAdjustLegacy", true);
7145+
static LLCachedControl<bool> should_auto_adjust(gSavedSettings, "RenderSkyAutoAdjustLegacy", false);
71467146

71477147
LLSettingsSky::ptr_t psky = LLEnvironment::instance().getCurrentSky();
71487148

@@ -7192,7 +7192,7 @@ void LLPipeline::gammaCorrect(LLRenderTarget* src, LLRenderTarget* dst)
71927192
LLGLDepthTest depth(GL_FALSE, GL_FALSE);
71937193

71947194
static LLCachedControl<bool> buildNoPost(gSavedSettings, "RenderDisablePostProcessing", false);
7195-
static LLCachedControl<bool> should_auto_adjust(gSavedSettings, "RenderSkyAutoAdjustLegacy", true);
7195+
static LLCachedControl<bool> should_auto_adjust(gSavedSettings, "RenderSkyAutoAdjustLegacy", false);
71967196

71977197
LLSettingsSky::ptr_t psky = LLEnvironment::instance().getCurrentSky();
71987198
LLGLSLShader& shader = psky->getReflectionProbeAmbiance(should_auto_adjust) == 0.f ? gLegacyPostGammaCorrectProgram :
@@ -8318,7 +8318,7 @@ void LLPipeline::bindDeferredShader(LLGLSLShader& shader, LLRenderTarget* light_
83188318
}
83198319

83208320
// auto adjust legacy sun color if needed
8321-
static LLCachedControl<bool> should_auto_adjust(gSavedSettings, "RenderSkyAutoAdjustLegacy", true);
8321+
static LLCachedControl<bool> should_auto_adjust(gSavedSettings, "RenderSkyAutoAdjustLegacy", false);
83228322
static LLCachedControl<F32> auto_adjust_sun_color_scale(gSavedSettings, "RenderSkyAutoAdjustSunColorScale", 1.f);
83238323
LLSettingsSky::ptr_t psky = LLEnvironment::instance().getCurrentSky();
83248324
LLColor3 sun_diffuse(mSunDiffuse.mV);

0 commit comments

Comments
 (0)