diff options
author | Oz Linden <oz@lindenlab.com> | 2011-05-25 08:45:39 -0400 |
---|---|---|
committer | Oz Linden <oz@lindenlab.com> | 2011-05-25 08:45:39 -0400 |
commit | c5987522881a5254dd070d4f8daedb80ede4b2b8 (patch) | |
tree | 8bc8254ab3c7e43619090376c7e55c2722098416 /indra/newview/llwlparammanager.cpp | |
parent | 551d17f819ea3dbcdc61cb41a458ab6d893d28cf (diff) | |
parent | 72d1efb1529ad0863d35b219a461f353a4b19353 (diff) |
merge lastest updates from windlight integration branch
Diffstat (limited to 'indra/newview/llwlparammanager.cpp')
-rw-r--r-- | indra/newview/llwlparammanager.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/indra/newview/llwlparammanager.cpp b/indra/newview/llwlparammanager.cpp index d64e2420e4..ec7889cb93 100644 --- a/indra/newview/llwlparammanager.cpp +++ b/indra/newview/llwlparammanager.cpp @@ -234,6 +234,7 @@ std::map<LLWLParamKey, LLWLParamSet> LLWLParamManager::finalizeFromDayCycle(LLWL return final_references; } +// static LLSD LLWLParamManager::createSkyMap(std::map<LLWLParamKey, LLWLParamSet> refs) { LLSD skies = LLSD::emptyMap(); @@ -588,10 +589,12 @@ void LLWLParamManager::applyUserPrefs(bool interpolate) // Remove all region sky presets because they may belong to a previously visited region. clearParamSetsOfScope(LLEnvKey::SCOPE_REGION); + // Add all sky presets belonging to the current region. + const LLEnvironmentSettings& region_settings = LLEnvManagerNew::instance().getRegionSettings(); + addAllSkies(LLEnvKey::SCOPE_REGION, region_settings.getSkyMap()); + if (LLEnvManagerNew::instance().getUseRegionSettings()) // apply region-wide settings { - const LLEnvironmentSettings& region_settings = LLEnvManagerNew::instance().getRegionSettings(); - if (region_settings.getSkyMap().size() == 0) { applyDefaults(); @@ -601,9 +604,6 @@ void LLWLParamManager::applyUserPrefs(bool interpolate) // *TODO: Support fixed sky from region. LL_DEBUGS("Windlight") << "Applying region sky" << LL_ENDL; - // Add all sky presets belonging to the current region. - addAllSkies(LLEnvKey::SCOPE_REGION, region_settings.getSkyMap()); - // Apply region day cycle. mDay.loadDayCycle(region_settings.getWLDayCycle(), LLEnvKey::SCOPE_REGION); resetAnimator(region_settings.getDayTime(), true); |