Jeck - It wasn't emptying the cache properly, so this is a step in the right direction. I'll keep looking for more issues, though.

This commit is contained in:
wagic.jeck
2009-09-03 18:21:57 +00:00
parent 3db0969c0e
commit 8340fdbd5b
4 changed files with 45 additions and 30 deletions

View File

@@ -7,6 +7,7 @@
#include "MTGCard.h"
#define CACHE_SIZE_PIXELS 2000000
#define MAX_CACHE_OBJECTS 100
class WCachedResource{
public:
@@ -106,6 +107,7 @@ private:
bool RemoveOldestTexture();
bool RemoveOldestSample();
bool cleanup();
void clearSamples();
WCachedTexture * getCachedTexture(string filename, bool makenew = true, int mode = 0, int format = TEXTURE_FORMAT);
WCachedTexture * getCachedCard(MTGCard * card, int type = CACHE_CARD, bool makenew = true);