diff options
author | Rider Linden <rider@lindenlab.com> | 2017-09-27 09:36:26 -0700 |
---|---|---|
committer | Rider Linden <rider@lindenlab.com> | 2017-09-27 09:36:26 -0700 |
commit | 52b0d4173cec0f643f37d426aef8f5ab1fdf3232 (patch) | |
tree | 5e2cb3e2ea12cabe81bb4a6b134968109e3414b4 /indra/newview/llvowlsky.cpp | |
parent | 0d414c1fb579dffc122c4d021a84cd126c612e54 (diff) |
No longer 'goth windlight only', sky parameters passed from settings object.
Diffstat (limited to 'indra/newview/llvowlsky.cpp')
-rw-r--r-- | indra/newview/llvowlsky.cpp | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/indra/newview/llvowlsky.cpp b/indra/newview/llvowlsky.cpp index 16130b5ca7..aff155637e 100644 --- a/indra/newview/llvowlsky.cpp +++ b/indra/newview/llvowlsky.cpp @@ -32,8 +32,9 @@ #include "llsky.h" #include "lldrawpoolwlsky.h" #include "llface.h" -#include "llwlparammanager.h" #include "llviewercontrol.h" +#include "llenvironment.h" +#include "llsettingssky.h" #define DOME_SLICES 1 const F32 LLVOWLSky::DISTANCE_TO_STARS = (HORIZON_DIST - 10.f)*0.25f; @@ -232,7 +233,7 @@ void subdivide(LLVertexBuffer& in, LLVertexBuffer* ret) void chop(LLVertexBuffer& in, LLVertexBuffer* out) { //chop off all triangles below horizon - F32 d = LLWLParamManager::sParamMgr->getDomeOffset() * LLWLParamManager::sParamMgr->getDomeRadius(); + F32 d = LLEnvironment::instance().getCamHeight(); std::vector<LLVector3> vert; @@ -399,7 +400,7 @@ BOOL LLVOWLSky::updateGeometry(LLDrawable * drawable) #else mStripsVerts = new LLVertexBuffer(LLDrawPoolWLSky::SKY_VERTEX_DATA_MASK, GL_STATIC_DRAW_ARB); - const F32 RADIUS = LLWLParamManager::sParamMgr->getDomeRadius(); + const F32 RADIUS = LLEnvironment::getCurrentSky()->getDomeRadius(); LLPointer<LLVertexBuffer> temp = new LLVertexBuffer(LLVertexBuffer::MAP_VERTEX, 0); temp->allocateBuffer(12, 60, TRUE); @@ -574,7 +575,7 @@ void LLVOWLSky::buildFanBuffer(LLStrider<LLVector3> & vertices, LLStrider<LLVector2> & texCoords, LLStrider<U16> & indices) { - const F32 RADIUS = LLWLParamManager::getInstance()->getDomeRadius(); + const F32 RADIUS = LLEnvironment::instance().getCurrentSky()->getDomeRadius(); U32 i, num_slices; F32 phi0, theta, x0, y0, z0; @@ -635,7 +636,7 @@ void LLVOWLSky::buildStripsBuffer(U32 begin_stack, U32 end_stack, LLStrider<LLVector2> & texCoords, LLStrider<U16> & indices) { - const F32 RADIUS = LLWLParamManager::getInstance()->getDomeRadius(); + const F32 RADIUS = LLEnvironment::instance().getCurrentSky()->getDomeRadius(); U32 i, j, num_slices, num_stacks; F32 phi0, theta, x0, y0, z0; |