summaryrefslogtreecommitdiff
path: root/indra/newview/lldrawpoolwlsky.cpp
diff options
context:
space:
mode:
authorMark Palange <palange@lindenlab.com>2008-11-07 17:51:03 +0000
committerMark Palange <palange@lindenlab.com>2008-11-07 17:51:03 +0000
commitf89f19990cbb9f3f2e7473ac6c159098bdfabec7 (patch)
treee7fa406e2db5e9adc2e24e00557d7b3d3f93203a /indra/newview/lldrawpoolwlsky.cpp
parentb2bfb128e7d30e1cdb293a2ac192a0cbe63fe528 (diff)
QAR-992 Merging revisions 101012-101170,101686-101687 of svn+ssh://svn.lindenlab.com/svn/linden/qa/viewer_combo_1-22-merge into linden/release
Diffstat (limited to 'indra/newview/lldrawpoolwlsky.cpp')
-rw-r--r--indra/newview/lldrawpoolwlsky.cpp13
1 files changed, 7 insertions, 6 deletions
diff --git a/indra/newview/lldrawpoolwlsky.cpp b/indra/newview/lldrawpoolwlsky.cpp
index 9f22d2aa0f..d8aa555752 100644
--- a/indra/newview/lldrawpoolwlsky.cpp
+++ b/indra/newview/lldrawpoolwlsky.cpp
@@ -159,7 +159,7 @@ void LLDrawPoolWLSky::renderStars(void) const
// *NOTE: have to have bound the cloud noise texture already since register
// combiners blending below requires something to be bound
// and we might as well only bind once.
- //LLGLEnable gl_texture_2d(GL_TEXTURE_2D);
+ //gGL.getTexUnit(0)->enable(LLTexUnit::TT_TEXTURE);
gPipeline.disableLights();
@@ -202,7 +202,8 @@ void LLDrawPoolWLSky::renderSkyClouds(F32 camHeightLocal) const
LLGLSBlendFunc blendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
gGL.setAlphaRejectSettings(LLRender::CF_DEFAULT);
- sCloudNoiseTexture->bind();
+ gGL.getTexUnit(0)->bind(sCloudNoiseTexture);
+
shader->bind();
/// Render the skydome
@@ -223,7 +224,7 @@ void LLDrawPoolWLSky::renderHeavenlyBodies()
if (gSky.mVOSkyp->getSun().getDraw() && face->getGeomCount())
{
LLImageGL * tex = face->getTexture();
- tex->bind();
+ gGL.getTexUnit(0)->bind(tex);
LLColor4 color(gSky.mVOSkyp->getSun().getInterpColor());
LLFacePool::LLOverrideFaceColor color_override(this, color);
face->renderIndexed();
@@ -238,7 +239,7 @@ void LLDrawPoolWLSky::renderHeavenlyBodies()
// stars register combiners, we bind again here for defensive reasons,
// since LLImageGL::bind detects that it's a noop, and optimizes it out.
LLImageGL * tex = face->getTexture();
- tex->bind();
+ gGL.getTexUnit(0)->bind(tex);
LLColor4 color(gSky.mVOSkyp->getMoon().getInterpColor());
F32 a = gSky.mVOSkyp->getMoon().getDirection().mV[2];
if (a > 0.f)
@@ -280,7 +281,7 @@ void LLDrawPoolWLSky::render(S32 pass)
// renderStars() requires something to be bound and we might as well only
// bind the moon's texture once.
LLImageGL * tex = gSky.mVOSkyp->mFace[LLVOSky::FACE_MOON]->getTexture();
- tex->bind();
+ gGL.getTexUnit(0)->bind(tex);
renderHeavenlyBodies();
@@ -291,7 +292,7 @@ void LLDrawPoolWLSky::render(S32 pass)
renderSkyClouds(camHeightLocal);
- LLImageGL::unbindTexture(0);
+ gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE);
}
void LLDrawPoolWLSky::prerender()