summaryrefslogtreecommitdiff
path: root/indra/newview
diff options
context:
space:
mode:
authorXiaohong Bao <bao@lindenlab.com>2010-08-23 11:32:58 -0600
committerXiaohong Bao <bao@lindenlab.com>2010-08-23 11:32:58 -0600
commit17553add7c13c4dbed678ef01cb25174722b9bd8 (patch)
tree4f82f3dd76eb8b1a755c3f2668fda5d66202c0c8 /indra/newview
parent116382fdf78ca578a74c30a162208033fd021124 (diff)
added a toggle "LLGLManager::mDebugGPU" for debugging certain CPUs.
added more debug code for EXT-6791: [crashhunters] Intel 965 Crash in glCopyTexSubImage2D
Diffstat (limited to 'indra/newview')
-rw-r--r--indra/newview/lldynamictexture.cpp18
1 files changed, 13 insertions, 5 deletions
diff --git a/indra/newview/lldynamictexture.cpp b/indra/newview/lldynamictexture.cpp
index bb4e6c7a3e..48b07bcf51 100644
--- a/indra/newview/lldynamictexture.cpp
+++ b/indra/newview/lldynamictexture.cpp
@@ -170,9 +170,12 @@ void LLViewerDynamicTexture::postRender(BOOL success)
if(!mGLTexturep->getHasGLTexture())
{
generateGLTexture() ;
- }
- llcallstacks << "class type: " << (S32)getType() << llcallstacksendl ;
+ }
+ if(gGLManager.mDebugGPU)
+ {
+ LLGLState::dumpStates() ;
+ }
success = mGLTexturep->setSubImageFromFrameBuffer(0, 0, mOrigin.mX, mOrigin.mY, mFullWidth, mFullHeight);
}
}
@@ -211,11 +214,16 @@ BOOL LLViewerDynamicTexture::updateAllInstances()
{
LLViewerDynamicTexture *dynamicTexture = *iter;
if (dynamicTexture->needsRender())
- {
+ {
+ if(gGLManager.mDebugGPU)
+ {
+ llinfos << "class type: " << (S32)dynamicTexture->getType() << llendl;
+ LLGLState::dumpStates() ;
+ }
+
glClear(GL_DEPTH_BUFFER_BIT);
gDepthDirty = TRUE;
-
-
+
gGL.color4f(1,1,1,1);
dynamicTexture->preRender(); // Must be called outside of startRender()
result = FALSE;