summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGraham Linden <graham@lindenlab.com>2018-09-17 19:48:58 +0100
committerGraham Linden <graham@lindenlab.com>2018-09-17 19:48:58 +0100
commit9581a197aceba7647ab9153513089570f11c4f9a (patch)
tree675428c5fb0ed0b0f1b02248b37ebc29ba734e74
parent57d89c80945ee0944f745b812487b6e3c16631d2 (diff)
SL-1873
Make range of star brightness in code and in UI 0-500 (not 512).
-rw-r--r--indra/llinventory/llsettingssky.cpp4
-rw-r--r--indra/newview/lldrawpoolwlsky.cpp2
-rw-r--r--indra/newview/skins/default/xui/en/panel_settings_sky_sunmoon.xml2
3 files changed, 4 insertions, 4 deletions
diff --git a/indra/llinventory/llsettingssky.cpp b/indra/llinventory/llsettingssky.cpp
index 56449c0598..399692d80b 100644
--- a/indra/llinventory/llsettingssky.cpp
+++ b/indra/llinventory/llsettingssky.cpp
@@ -534,7 +534,7 @@ LLSettingsSky::validation_list_t LLSettingsSky::validationList()
boost::bind(&Validator::verifyFloatRange, _1, LLSD(LLSDArray(0.25f)(20.0f))), LLSD::Real(1.0)));
validation.push_back(Validator(SETTING_MOON_TEXTUREID, false, LLSD::TypeUUID));
validation.push_back(Validator(SETTING_STAR_BRIGHTNESS, true, LLSD::TypeReal,
- boost::bind(&Validator::verifyFloatRange, _1, LLSD(LLSDArray(0.0f)(512.0f)))));
+ boost::bind(&Validator::verifyFloatRange, _1, LLSD(LLSDArray(0.0f)(500.0f)))));
validation.push_back(Validator(SETTING_SUNLIGHT_COLOR, true, LLSD::TypeArray,
boost::bind(&Validator::verifyVectorMinMax, _1,
LLSD(LLSDArray(0.0f)(0.0f)(0.0f)("*")),
@@ -784,7 +784,7 @@ LLSD LLSettingsSky::translateLegacySettings(const LLSD& legacy)
}
if (legacy.has(SETTING_STAR_BRIGHTNESS))
{
- newsettings[SETTING_STAR_BRIGHTNESS] = LLSD::Real(legacy[SETTING_STAR_BRIGHTNESS].asReal()) * 256.0f;
+ newsettings[SETTING_STAR_BRIGHTNESS] = LLSD::Real(legacy[SETTING_STAR_BRIGHTNESS].asReal() * 250.0f);
}
if (legacy.has(SETTING_SUNLIGHT_COLOR))
{
diff --git a/indra/newview/lldrawpoolwlsky.cpp b/indra/newview/lldrawpoolwlsky.cpp
index def2c5263d..76c0bd5abf 100644
--- a/indra/newview/lldrawpoolwlsky.cpp
+++ b/indra/newview/lldrawpoolwlsky.cpp
@@ -293,7 +293,7 @@ void LLDrawPoolWLSky::renderStarsDeferred(void) const
LLGLEnable blend(GL_BLEND);
gGL.setSceneBlendType(LLRender::BT_ADD_WITH_ALPHA);
- F32 star_alpha = LLEnvironment::instance().getCurrentSky()->getStarBrightness() / 512.0f;
+ F32 star_alpha = LLEnvironment::instance().getCurrentSky()->getStarBrightness() / 500.0f;
// If start_brightness is not set, exit
if(star_alpha < 0.001f)
diff --git a/indra/newview/skins/default/xui/en/panel_settings_sky_sunmoon.xml b/indra/newview/skins/default/xui/en/panel_settings_sky_sunmoon.xml
index 0ec3528718..841a8c3199 100644
--- a/indra/newview/skins/default/xui/en/panel_settings_sky_sunmoon.xml
+++ b/indra/newview/skins/default/xui/en/panel_settings_sky_sunmoon.xml
@@ -171,7 +171,7 @@
layout="topleft"
left_delta="5"
min_val="0"
- max_val="512"
+ max_val="500"
name="star_brightness"
top_delta="15"
width="250"