4 /* A short program which converts a .gif file into a .gd file, for
5 your convenience in creating images on the fly from a
6 basis image that must be loaded quickly. The .gd format
7 is not intended to be a general-purpose format. */
9 int main(int argc, char **argv)
14 fprintf(stderr, "Usage: giftogd filename.gif filename.gd\n");
17 in = fopen(argv[1], "rb");
19 fprintf(stderr, "Input file does not exist!\n");
22 im = gdImageCreateFromGif(in);
25 fprintf(stderr, "Input is not in GIF format!\n");
28 out = fopen(argv[2], "wb");
30 fprintf(stderr, "Output file cannot be written to!\n");