]> git.rm.cloudns.org Git - xonotic/darkplaces.git/commitdiff
Woops - use -1 to mark dirty textures!
authorblack <black@d7cf8633-e32d-0410-b094-e92efae38249>
Tue, 27 Nov 2007 22:39:46 +0000 (22:39 +0000)
committerblack <black@d7cf8633-e32d-0410-b094-e92efae38249>
Tue, 27 Nov 2007 22:39:46 +0000 (22:39 +0000)
git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@7719 d7cf8633-e32d-0410-b094-e92efae38249

gl_textures.c

index ee9277129d297824150d3481d489141c7c3ce179..a57fe01295f00ef39b6e8a11085b4d377e8e8776 100644 (file)
@@ -226,7 +226,7 @@ void R_MarkDirtyTexture(rtexture_t *rt) {
        if( !glt->dirtytexnum && glt->flags & GLTEXF_DYNAMIC ) {
                glt->dirtytexnum = glt->texnum;
                // mark it as dirty, so R_RealGetTexture gets called
-               glt->texnum = 0;
+               glt->texnum = -1;
        }
 }
 
@@ -239,6 +239,7 @@ void R_MakeTextureDynamic(rtexture_t *rt, updatecallback_t updatecallback, void
        glt->flags |= GLTEXF_DYNAMIC;
        glt->updatecallback = updatecallback;
        glt->updatacallback_data = data;
+       glt->dirtytexnum = 0;
 }
 
 static void R_UpdateDynamicTexture(gltexture_t *glt) {