summaryrefslogtreecommitdiff
path: root/indra/newview/lldrawpoolwlsky.cpp
diff options
context:
space:
mode:
authorGraham Linden <graham@lindenlab.com>2018-10-02 00:57:32 +0100
committerGraham Linden <graham@lindenlab.com>2018-10-02 00:57:32 +0100
commitb4d6611ea7e5f3dfe01e7c7f7dae9c5b2c2347b8 (patch)
treef2304ff568bf7f8c9a574530a477bf864cb877c6 /indra/newview/lldrawpoolwlsky.cpp
parentc98522a40ec6855a11a781301fca7a3943ba5a25 (diff)
SL-9775
Add LLPointer<> on stack to avoid textures being deleted out from under the sky code. Make textures used by sky settings remove their faces from media textures. Add ability to detect when a given texture is viewer media with vfunc.
Diffstat (limited to 'indra/newview/lldrawpoolwlsky.cpp')
-rw-r--r--indra/newview/lldrawpoolwlsky.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/indra/newview/lldrawpoolwlsky.cpp b/indra/newview/lldrawpoolwlsky.cpp
index a796052635..5104dc18fd 100644
--- a/indra/newview/lldrawpoolwlsky.cpp
+++ b/indra/newview/lldrawpoolwlsky.cpp
@@ -392,8 +392,8 @@ void LLDrawPoolWLSky::renderHeavenlyBodies()
if (gSky.mVOSkyp->getSun().getDraw() && face && face->getGeomCount())
{
- LLViewerTexture* tex_a = face->getTexture(LLRender::DIFFUSE_MAP);
- LLViewerTexture* tex_b = face->getTexture(LLRender::ALTERNATE_DIFFUSE_MAP);
+ LLPointer<LLViewerTexture> tex_a = face->getTexture(LLRender::DIFFUSE_MAP);
+ LLPointer<LLViewerTexture> tex_b = face->getTexture(LLRender::ALTERNATE_DIFFUSE_MAP);
gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE);
gGL.getTexUnit(1)->unbind(LLTexUnit::TT_TEXTURE);