Skip to content

#3511 fix for PBR skies being too bright on Low Graphics #3570

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion indra/llinventory/llsettingssky.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,8 @@ const std::string LLSettingsSky::SETTING_REFLECTION_PROBE_AMBIANCE("reflection_p

const LLUUID LLSettingsSky::DEFAULT_ASSET_ID("651510b8-5f4d-8991-1592-e7eeab2a5a06");

F32 LLSettingsSky::sAutoAdjustProbeAmbiance = 1.f;
const F32 LLSettingsSky::DEFAULT_AUTO_ADJUST_PROBE_AMBIANCE = 1.f;
F32 LLSettingsSky::sAutoAdjustProbeAmbiance = DEFAULT_AUTO_ADJUST_PROBE_AMBIANCE;

static const LLUUID DEFAULT_SUN_ID("32bfbcea-24b1-fb9d-1ef9-48a28a63730f"); // dataserver
static const LLUUID DEFAULT_MOON_ID("d07f6eed-b96a-47cd-b51d-400ad4a1c428"); // dataserver
Expand Down
1 change: 1 addition & 0 deletions indra/llinventory/llsettingssky.h
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,7 @@ class LLSettingsSky: public LLSettingsBase

static const LLUUID DEFAULT_ASSET_ID;

static const F32 DEFAULT_AUTO_ADJUST_PROBE_AMBIANCE;
static F32 sAutoAdjustProbeAmbiance;

typedef PTR_NAMESPACE::shared_ptr<LLSettingsSky> ptr_t;
Expand Down
4 changes: 4 additions & 0 deletions indra/newview/llsettingsvo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -832,6 +832,10 @@ void LLSettingsVOSky::applySpecial(void *ptarget, bool force)
{
shader->uniform3fv(LLShaderMgr::AMBIENT, LLVector3(ambient.mV));
shader->uniform1f(LLShaderMgr::SKY_HDR_SCALE, sqrtf(g)*2.0f); // use a modifier here so 1.0 maps to the "most desirable" default and the maximum value doesn't go off the rails

// Low quality setting
if (!LLPipeline::sReflectionProbesEnabled)
probe_ambiance = DEFAULT_AUTO_ADJUST_PROBE_AMBIANCE;
}
else if (psky->canAutoAdjust() && should_auto_adjust)
{ // auto-adjust legacy sky to take advantage of probe ambiance
Expand Down