summaryrefslogtreecommitdiff
path: root/indra/newview
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview')
-rw-r--r--indra/newview/llsurface.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/indra/newview/llsurface.cpp b/indra/newview/llsurface.cpp
index eadb311919..5440b2c9ad 100644
--- a/indra/newview/llsurface.cpp
+++ b/indra/newview/llsurface.cpp
@@ -265,7 +265,7 @@ void LLSurface::createWaterTexture()
if (!mWaterTexturep)
{
// Create the water texture
- /*LLPointer<LLImageRaw> raw = new LLImageRaw(sTextureSize/2, sTextureSize/2, 4);
+ LLPointer<LLImageRaw> raw = new LLImageRaw(sTextureSize/2, sTextureSize/2, 4);
U8 *default_texture = raw->getData();
for (S32 i = 0; i < sTextureSize/2; i++)
{
@@ -276,11 +276,11 @@ void LLSurface::createWaterTexture()
*(default_texture + (i*sTextureSize/2 + j)*4 + 2) = MAX_WATER_COLOR.mV[2];
*(default_texture + (i*sTextureSize/2 + j)*4 + 3) = MAX_WATER_COLOR.mV[3];
}
- }*/
+ }
-
- mWaterTexturep = LLViewerTextureManager::getLocalTexture(sTextureSize/2, sTextureSize/2, 4, FALSE);
+ mWaterTexturep = LLViewerTextureManager::getLocalTexture(raw.get(), FALSE);
mWaterTexturep->dontDiscard();
+ gGL.getTexUnit(0)->bind(mWaterTexturep);
mWaterTexturep->setAddressMode(LLTexUnit::TAM_CLAMP);
}
}