summaryrefslogtreecommitdiff
path: root/indra/newview/lldynamictexture.cpp
diff options
context:
space:
mode:
authorVadim Savchuk <vsavchuk@productengine.com>2009-12-02 18:17:51 +0200
committerVadim Savchuk <vsavchuk@productengine.com>2009-12-02 18:17:51 +0200
commitabb23ff31260e9632406dae03be920a23220d719 (patch)
treea24029245cf2ca511f3893e1b42e04ac3e9a90db /indra/newview/lldynamictexture.cpp
parent9d8b189886ae14800d58f9729d8c8ea9b338ed52 (diff)
parentf496c2b164a100836d74909c3e27adcdf98018f0 (diff)
Manual merge from default branch.
--HG-- branch : product-engine
Diffstat (limited to 'indra/newview/lldynamictexture.cpp')
-rw-r--r--indra/newview/lldynamictexture.cpp22
1 files changed, 12 insertions, 10 deletions
diff --git a/indra/newview/lldynamictexture.cpp b/indra/newview/lldynamictexture.cpp
index 9bc7221dc8..c7c79401a0 100644
--- a/indra/newview/lldynamictexture.cpp
+++ b/indra/newview/lldynamictexture.cpp
@@ -141,11 +141,12 @@ void LLViewerDynamicTexture::preRender(BOOL clear_depth)
gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE);
}
// Set up camera
- mCamera.setOrigin(*LLViewerCamera::getInstance());
- mCamera.setAxes(*LLViewerCamera::getInstance());
- mCamera.setAspect(LLViewerCamera::getInstance()->getAspect());
- mCamera.setView(LLViewerCamera::getInstance()->getView());
- mCamera.setNear(LLViewerCamera::getInstance()->getNear());
+ LLViewerCamera* camera = LLViewerCamera::getInstance();
+ mCamera.setOrigin(*camera);
+ mCamera.setAxes(*camera);
+ mCamera.setAspect(camera->getAspect());
+ mCamera.setView(camera->getView());
+ mCamera.setNear(camera->getNear());
glViewport(mOrigin.mX, mOrigin.mY, mFullWidth, mFullHeight);
if (clear_depth)
@@ -174,11 +175,12 @@ void LLViewerDynamicTexture::postRender(BOOL success)
gViewerWindow->setup2DViewport();
// restore camera
- LLViewerCamera::getInstance()->setOrigin(mCamera);
- LLViewerCamera::getInstance()->setAxes(mCamera);
- LLViewerCamera::getInstance()->setAspect(mCamera.getAspect());
- LLViewerCamera::getInstance()->setView(mCamera.getView());
- LLViewerCamera::getInstance()->setNear(mCamera.getNear());
+ LLViewerCamera* camera = LLViewerCamera::getInstance();
+ camera->setOrigin(mCamera);
+ camera->setAxes(mCamera);
+ camera->setAspect(mCamera.getAspect());
+ camera->setView(mCamera.getView());
+ camera->setNear(mCamera.getNear());
}
//-----------------------------------------------------------------------------