Files
@ r5312:ffd375effb01
Branch filter:
Location: cpp/openttd-patchpack/source/spritecache.h - annotation
r5312:ffd375effb01
667 B
text/x-c
(svn r7468) -Codechange: [win32] Add some comments to MB/WIDE_TO_WIDE/MB_[BUFFER] macros and
use them some more in win32 code. Also for the clipboard use the convert_from_fs
function instead of calling Win32 API directly. Make the static buffers in OTTD2FS
and FS2OTTD the same size (character-length wise)
use them some more in win32 code. Also for the clipboard use the convert_from_fs
function instead of calling Win32 API directly. Make the static buffers in OTTD2FS
and FS2OTTD the same size (character-length wise)
r2186:5ee653b1b5e1 r2186:5ee653b1b5e1 r1349:8fc4bdf6c588 r1349:8fc4bdf6c588 r1349:8fc4bdf6c588 r1350:2e611710fdde r1350:2e611710fdde r1350:2e611710fdde r1356:ce1373b836e5 r1356:ce1373b836e5 r1356:ce1373b836e5 r1350:2e611710fdde r1350:2e611710fdde r1350:2e611710fdde r1361:d1246fcfda96 r3565:99183437dfaa r1361:d1246fcfda96 r1361:d1246fcfda96 r1361:d1246fcfda96 r1361:d1246fcfda96 r1361:d1246fcfda96 r1361:d1246fcfda96 r1361:d1246fcfda96 r1361:d1246fcfda96 r1361:d1246fcfda96 r1361:d1246fcfda96 r1349:8fc4bdf6c588 r2340:fbdaeafc90de r1349:8fc4bdf6c588 r1349:8fc4bdf6c588 r2340:fbdaeafc90de r2407:bc0da484827c r2340:fbdaeafc90de r2340:fbdaeafc90de r2436:963efe8b84cc | /* $Id$ */
#ifndef SPRITECACHE_H
#define SPRITECACHE_H
typedef struct Sprite {
byte info;
byte height;
uint16 width;
int16 x_offs;
int16 y_offs;
byte data[VARARRAY_SIZE];
} Sprite;
const void *GetRawSprite(SpriteID sprite);
bool SpriteExists(SpriteID sprite);
static inline const Sprite *GetSprite(SpriteID sprite)
{
return GetRawSprite(sprite);
}
static inline const byte *GetNonSprite(SpriteID sprite)
{
return GetRawSprite(sprite);
}
void GfxInitSpriteMem(void);
void IncreaseSpriteLRU(void);
bool LoadNextSprite(int load_index, byte file_index);
void DupSprite(SpriteID old, SpriteID new);
void SkipSprites(uint count);
#endif /* SPRITECACHE_H */
|