]> git.xonotic.org Git - xonotic/darkplaces.git/commitdiff
Draw_CachePic_Flags: ignore TEXF_COMPRESS when comparing, because fallback pics remov...
authordivverent <divverent@d7cf8633-e32d-0410-b094-e92efae38249>
Thu, 19 Aug 2010 05:35:16 +0000 (05:35 +0000)
committerdivverent <divverent@d7cf8633-e32d-0410-b094-e92efae38249>
Thu, 19 Aug 2010 05:35:16 +0000 (05:35 +0000)
git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@10396 d7cf8633-e32d-0410-b094-e92efae38249

gl_draw.c

index 3161e7fa73ad32bb571fc1290f43f8b19f3e1c92..7fdde68f6587992d55f978ed8b2e2e8a820bce1c 100644 (file)
--- a/gl_draw.c
+++ b/gl_draw.c
@@ -331,7 +331,7 @@ cachepic_t *Draw_CachePic_Flags(const char *path, unsigned int cachepicflags)
        hashkey = ((crc >> 8) ^ crc) % CACHEPICHASHSIZE;
        for (pic = cachepichash[hashkey];pic;pic = pic->chain)
                if (!strcmp (path, pic->name))
-                       if(pic->texflags == texflags)
+                       if(!((pic->texflags ^ texflags) & ~(TEXF_COMPRESS))) // ignore TEXF_COMPRESS when comparing, because fallback pics remove the flag
                        {
                                if(!(cachepicflags & CACHEPICFLAG_NOTPERSISTENT))
                                        pic->autoload = false; // persist it