return -1;
}
+void lbximg_getinfo(struct lbx_image *img, struct lbx_imginfo *info)
+{
+ *info = (struct lbx_imginfo) {
+ .width = img->width,
+ .height = img->height,
+ .nframes = img->frames,
+ };
+}
+
void lbximg_close(struct lbx_image *img)
{
if (!img) return;
unsigned char blue;
};
+struct lbx_imginfo {
+ unsigned int width, height;
+ unsigned int nframes;
+};
+
LBX_IMG *lbximg_fopen(FILE *f);
void lbximg_close(LBX_IMG *img);
unsigned char **lbximg_getframe(LBX_IMG *img, int frame);
int lbximg_loadpalette(FILE *f, struct lbx_colour palette[static 256]);
int lbximg_getpalette(LBX_IMG *img, struct lbx_colour palette[static 256]);
+void lbximg_getinfo(LBX_IMG *img, struct lbx_imginfo *info);
+
#endif