2005-07-24 16:12:37 +02:00
|
|
|
/* $Id$ */
|
|
|
|
|
2005-02-10 06:43:30 +01:00
|
|
|
#ifndef SPRITECACHE_H
|
|
|
|
#define SPRITECACHE_H
|
|
|
|
|
2005-02-10 13:14:38 +01:00
|
|
|
typedef struct Sprite {
|
|
|
|
byte info;
|
|
|
|
byte height;
|
2005-02-11 16:18:09 +01:00
|
|
|
uint16 width;
|
|
|
|
int16 x_offs;
|
|
|
|
int16 y_offs;
|
2005-02-10 13:14:38 +01:00
|
|
|
byte data[VARARRAY_SIZE];
|
|
|
|
} Sprite;
|
|
|
|
|
2005-02-13 09:12:03 +01:00
|
|
|
const void *GetRawSprite(SpriteID sprite);
|
2006-04-16 13:26:23 +02:00
|
|
|
bool SpriteExists(SpriteID sprite);
|
2005-02-13 09:12:03 +01:00
|
|
|
|
|
|
|
static inline const Sprite *GetSprite(SpriteID sprite)
|
|
|
|
{
|
|
|
|
return GetRawSprite(sprite);
|
|
|
|
}
|
|
|
|
|
|
|
|
static inline const byte *GetNonSprite(SpriteID sprite)
|
|
|
|
{
|
|
|
|
return GetRawSprite(sprite);
|
|
|
|
}
|
2005-02-10 06:43:30 +01:00
|
|
|
|
2005-08-14 20:10:18 +02:00
|
|
|
void GfxInitSpriteMem(void);
|
2005-02-10 06:43:30 +01:00
|
|
|
void IncreaseSpriteLRU(void);
|
|
|
|
|
2005-08-14 20:10:18 +02:00
|
|
|
bool LoadNextSprite(int load_index, byte file_index);
|
2005-09-10 10:17:30 +02:00
|
|
|
void DupSprite(SpriteID old, SpriteID new);
|
2005-08-14 20:10:18 +02:00
|
|
|
void SkipSprites(uint count);
|
|
|
|
|
2005-09-18 22:56:44 +02:00
|
|
|
#endif /* SPRITECACHE_H */
|