-
Notifications
You must be signed in to change notification settings - Fork 2
/
loaf.h
78 lines (68 loc) · 1.48 KB
/
loaf.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
/* :ts=8 bk=0
*
* loaf.h: Structures for handling LOAF data.
*
* Leo L. Schwab 9304.29
*/
/***************************************************************************
* In-memory structures.
*/
typedef struct ImageEnv {
struct ImageEntry *iev_ImageEntries;
struct AnimEntry *iev_AnimEntries;
struct ShortCCB *iev_SCCBs;
uint16 *iev_PLUTBuf;
ubyte *iev_PDATBuf;
int32 iev_NImageEntries,
iev_NAnimEntries,
iev_NSCCBs,
iev_PLUTBufSiz,
iev_PDATBufSiz;
} ImageEnv;
typedef struct ImageEntry {
struct ShortCCB *ie_SCCB;
uint16 *ie_PLUT;
uint32 ie_PPMPC;
} ImageEntry;
typedef struct AnimEntry {
struct ImageEntry *ae_Base;
struct ImageEntry *ae_Target;
int32 ae_NFrames;
int32 ae_FPS;
} AnimEntry;
typedef struct ShortCCB {
uint32 sccb_Flags;
uint32 sccb_PRE0,
sccb_PRE1;
int32 sccb_Width,
sccb_Height;
void *sccb_PDAT;
} ShortCCB;
/***************************************************************************
* On-disk structures.
*/
/*
* Image Entries.
*/
typedef struct DiskImageEntry {
uint32 die_SCCBIdx;
uint32 die_PLUTIdx;
uint32 die_PPMPC;
} DiskImageEntry;
/*
* Short CCBs.
*/
typedef struct DiskShortCCB {
uint32 dsc_Flags;
uint32 dsc_PRE0,
dsc_PRE1;
int32 dsc_Width,
dsc_Height;
int32 dsc_PDATSize;
} DiskShortCCB;
typedef struct DiskAnimEntry {
uint32 dae_Marker; /* == ~0 */
uint32 dae_ImageIdx; /* Index into self. */
uint16 dae_NFrames, /* Guess... */
dae_FPS; /* Frames per second. */
} DiskAnimEntry;