summaryrefslogtreecommitdiff
path: root/indra/llinventory/llsettingssky.h
diff options
context:
space:
mode:
Diffstat (limited to 'indra/llinventory/llsettingssky.h')
-rw-r--r--indra/llinventory/llsettingssky.h126
1 files changed, 74 insertions, 52 deletions
diff --git a/indra/llinventory/llsettingssky.h b/indra/llinventory/llsettingssky.h
index 8b2118fd84..d08e2bbd03 100644
--- a/indra/llinventory/llsettingssky.h
+++ b/indra/llinventory/llsettingssky.h
@@ -38,6 +38,10 @@ public:
static const std::string SETTING_BLOOM_TEXTUREID;
static const std::string SETTING_BLUE_DENSITY;
static const std::string SETTING_BLUE_HORIZON;
+ static const std::string SETTING_DENSITY_MULTIPLIER;
+ static const std::string SETTING_DISTANCE_MULTIPLIER;
+ static const std::string SETTING_HAZE_DENSITY;
+ static const std::string SETTING_HAZE_HORIZON;
static const std::string SETTING_CLOUD_COLOR;
static const std::string SETTING_CLOUD_POS_DENSITY1;
static const std::string SETTING_CLOUD_POS_DENSITY2;
@@ -45,14 +49,10 @@ public:
static const std::string SETTING_CLOUD_SCROLL_RATE;
static const std::string SETTING_CLOUD_SHADOW;
static const std::string SETTING_CLOUD_TEXTUREID;
- static const std::string SETTING_DENSITY_MULTIPLIER;
- static const std::string SETTING_DISTANCE_MULTIPLIER;
static const std::string SETTING_DOME_OFFSET;
static const std::string SETTING_DOME_RADIUS;
static const std::string SETTING_GAMMA;
- static const std::string SETTING_GLOW;
- static const std::string SETTING_HAZE_DENSITY;
- static const std::string SETTING_HAZE_HORIZON;
+ static const std::string SETTING_GLOW;
static const std::string SETTING_LIGHT_NORMAL;
static const std::string SETTING_MAX_Y;
static const std::string SETTING_MOON_ROTATION;
@@ -60,7 +60,24 @@ public:
static const std::string SETTING_STAR_BRIGHTNESS;
static const std::string SETTING_SUNLIGHT_COLOR;
static const std::string SETTING_SUN_ROTATION;
- static const std::string SETTING_SUN_TEXUTUREID;
+ static const std::string SETTING_SUN_TEXTUREID;
+
+ static const std::string SETTING_PLANET_RADIUS;
+ static const std::string SETTING_SKY_BOTTOM_RADIUS;
+ static const std::string SETTING_SKY_TOP_RADIUS;
+ static const std::string SETTING_SUN_ARC_RADIANS;
+
+ static const std::string SETTING_RAYLEIGH_CONFIG;
+ static const std::string SETTING_MIE_CONFIG;
+ static const std::string SETTING_ABSORPTION_CONFIG;
+
+ static const std::string KEY_DENSITY_PROFILE;
+ static const std::string SETTING_DENSITY_PROFILE_WIDTH;
+ static const std::string SETTING_DENSITY_PROFILE_EXP_TERM;
+ static const std::string SETTING_DENSITY_PROFILE_EXP_SCALE_FACTOR;
+ static const std::string SETTING_DENSITY_PROFILE_LINEAR_TERM;
+ static const std::string SETTING_DENSITY_PROFILE_CONSTANT_TERM;
+ static const std::string SETTING_MIE_ANISOTROPY_FACTOR;
typedef std::shared_ptr<LLSettingsSky> ptr_t;
typedef std::pair<F32, F32> azimalt_t;
@@ -81,6 +98,11 @@ public:
static LLSD defaults();
+ LLUUID getBloomTextureId() const
+ {
+ return mSettings[SETTING_BLOOM_TEXTUREID].asUUID();
+ }
+
//---------------------------------------------------------------------
LLColor3 getAmbientColor() const
{
@@ -92,11 +114,6 @@ public:
setValue(SETTING_AMBIENT, val);
}
- LLUUID getBloomTextureId() const
- {
- return mSettings[SETTING_BLOOM_TEXTUREID].asUUID();
- }
-
LLColor3 getBlueDensity() const
{
return LLColor3(mSettings[SETTING_BLUE_DENSITY]);
@@ -117,6 +134,46 @@ public:
setValue(SETTING_BLUE_HORIZON, val);
}
+ F32 getDensityMultiplier() const
+ {
+ return mSettings[SETTING_DENSITY_MULTIPLIER].asReal();
+ }
+
+ void setDensityMultiplier(F32 val)
+ {
+ setValue(SETTING_DENSITY_MULTIPLIER, val);
+ }
+
+ F32 getDistanceMultiplier() const
+ {
+ return mSettings[SETTING_DISTANCE_MULTIPLIER].asReal();
+ }
+
+ void setDistanceMultiplier(F32 val)
+ {
+ setValue(SETTING_DISTANCE_MULTIPLIER, val);
+ }
+
+ F32 getHazeDensity() const
+ {
+ return mSettings[SETTING_HAZE_DENSITY].asReal();
+ }
+
+ void setHazeDensity(F32 val)
+ {
+ setValue(SETTING_HAZE_DENSITY, val);
+ }
+
+ F32 getHazeHorizon() const
+ {
+ return mSettings[SETTING_HAZE_HORIZON].asReal();
+ }
+
+ void setHazeHorizon(F32 val)
+ {
+ setValue(SETTING_HAZE_HORIZON, val);
+ }
+
LLColor3 getCloudColor() const
{
return LLColor3(mSettings[SETTING_CLOUD_COLOR]);
@@ -194,26 +251,7 @@ public:
setValue(SETTING_CLOUD_SHADOW, val);
}
- F32 getDensityMultiplier() const
- {
- return mSettings[SETTING_DENSITY_MULTIPLIER].asReal();
- }
-
- void setDensityMultiplier(F32 val)
- {
- setValue(SETTING_DENSITY_MULTIPLIER, val);
- }
-
- F32 getDistanceMultiplier() const
- {
- return mSettings[SETTING_DISTANCE_MULTIPLIER].asReal();
- }
-
- void setDistanceMultiplier(F32 val)
- {
- setValue(SETTING_DISTANCE_MULTIPLIER, val);
- }
-
+
F32 getDomeOffset() const
{
return DOME_OFFSET;
@@ -247,26 +285,6 @@ public:
setValue(SETTING_GLOW, val);
}
- F32 getHazeDensity() const
- {
- return mSettings[SETTING_HAZE_DENSITY].asReal();
- }
-
- void setHazeDensity(F32 val)
- {
- setValue(SETTING_HAZE_DENSITY, val);
- }
-
- F32 getHazeHorizon() const
- {
- return mSettings[SETTING_HAZE_HORIZON].asReal();
- }
-
- void setHazeHorizon(F32 val)
- {
- setValue(SETTING_HAZE_HORIZON, val);
- }
-
LLVector3 getLightNormal() const
{
return LLVector3(mSettings[SETTING_LIGHT_NORMAL]);
@@ -347,7 +365,7 @@ public:
LLUUID getSunTextureId() const
{
- return mSettings[SETTING_SUN_TEXUTUREID].asUUID();
+ return mSettings[SETTING_SUN_TEXTUREID].asUUID();
}
// Internal/calculated settings
@@ -428,6 +446,10 @@ protected:
virtual void updateSettings() override;
private:
+ static LLSD rayleighConfigDefault();
+ static LLSD absorptionConfigDefault();
+ static LLSD mieConfigDefault();
+
static const F32 NIGHTTIME_ELEVATION;
static const F32 NIGHTTIME_ELEVATION_COS;