]> git.draconx.ca Git - liblbx.git/blob - src/image.h
Implement functions for loading palettes, and slightly improve the image reader.
[liblbx.git] / src / image.h
1 #ifndef LBXIMG_H_
2 #define LBXIMG_H_
3
4 #include <stdio.h>
5
6 typedef struct lbx_image LBXIMG;
7
8 struct lbx_colour {
9         unsigned char red;
10         unsigned char green;
11         unsigned char blue;
12 };
13
14 LBXIMG *lbximg_fopen(FILE *f);
15 void    lbximg_close(LBXIMG *img);
16 unsigned char **lbximg_getframe(LBXIMG *img, int frame);
17
18 int lbximg_loadpalette(FILE *f, struct lbx_colour palette[static 256]);
19 int lbximg_getpalette(LBXIMG *img, struct lbx_colour palette[static 256]);
20
21 #endif