From fb793870fe95f1951d7c30ea6068e187b9dededd Mon Sep 17 00:00:00 2001 From: Mark Palange Date: Tue, 23 Dec 2008 19:39:58 +0000 Subject: QAR-1142 merging 1.22 RC0-RC4 changes. svn merge -c 106471 svn+ssh://svn.lindenlab.com/svn/linden/qa/viewer_1-22-106055_merge --- indra/llrender/llimagegl.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'indra/llrender/llimagegl.cpp') diff --git a/indra/llrender/llimagegl.cpp b/indra/llrender/llimagegl.cpp index 2ef2bae1ab..9efadbd030 100644 --- a/indra/llrender/llimagegl.cpp +++ b/indra/llrender/llimagegl.cpp @@ -154,7 +154,7 @@ void LLImageGL::destroyGL(BOOL save_state) LLImageGL* glimage = *iter; if (glimage->mTexName && glimage->mComponents) { - if (save_state) + if (save_state && glimage->isInitialized()) { glimage->mSaveData = new LLImageRaw; glimage->readBackRaw(glimage->mCurrentDiscardLevel, glimage->mSaveData, false); @@ -748,7 +748,7 @@ BOOL LLImageGL::setSubImage(const LLImageRaw* imageraw, S32 x_pos, S32 y_pos, S3 // Copy sub image from frame buffer BOOL LLImageGL::setSubImageFromFrameBuffer(S32 fb_x, S32 fb_y, S32 x_pos, S32 y_pos, S32 width, S32 height) { - if (gGL.getTexUnit(0)->bind(this)) + if (gGL.getTexUnit(0)->bind(this, true)) { glCopyTexSubImage2D(GL_TEXTURE_2D, 0, fb_x, fb_y, x_pos, y_pos, width, height); mInitialized = true; -- cgit v1.2.3