static unsigned char *resizebuffer = NULL, *colorconvertbuffer;
static int resizebuffersize = 0;
-static unsigned char *texturebuffer;
+static const unsigned char *texturebuffer;
static int texturebuffersize = 0;
static textypeinfo_t *R_GetTexTypeInfo(textype_t textype, int flags)
return 0;
}
+void R_PurgeTexture(rtexture_t *rt)
+{
+ if(rt && !(((gltexture_t*) rt)->flags & TEXF_PERSISTENT)) {
+ R_FreeTexture(rt);
+ }
+}
+
void R_FreeTexture(rtexture_t *rt)
{
gltexture_t *glt, **gltpointer;
R_Upload(glt, data, x, y, 0, width, height, 1);
}
+void R_ClearTexture (rtexture_t *rt)
+{
+ gltexture_t *glt = (gltexture_t *)rt;
+
+ R_Upload( glt, NULL, 0, 0, 0, glt->tilewidth, glt->tileheight, glt->tiledepth );
+}