eobish

annotate src/image.h @ 4:ce0548d24918

mostly works
author John Tsiombikas <nuclear@member.fsf.org>
date Sun, 18 Jan 2015 13:30:30 +0200
parents
children
rev   line source
nuclear@4 1 #ifndef IMAGE_H_
nuclear@4 2 #define IMAGE_H_
nuclear@4 3
nuclear@4 4 struct color {
nuclear@4 5 int r, g, b;
nuclear@4 6 };
nuclear@4 7
nuclear@4 8 struct image {
nuclear@4 9 int xsz, ysz;
nuclear@4 10 unsigned char *pixels;
nuclear@4 11 };
nuclear@4 12
nuclear@4 13 int load_image(struct image *img, const char *fname);
nuclear@4 14 void destroy_image(struct image *img);
nuclear@4 15
nuclear@4 16 /* returns the number of palette entries loaded */
nuclear@4 17 int load_palette(struct color *col, const char *fname);
nuclear@4 18
nuclear@4 19 void blitkey(struct image *img, int x, int y, struct image *src, int key);
nuclear@4 20
nuclear@4 21 #endif /* IMAGE_H_ */