/* */ /* Iff2C - Converts an Iff ILBM file to C source */ /* */ /* Last updates: */ /* v0.30, 89.0512, fixed minor output bug, -ghg- */ /* v0.29, 89.0501, plane pick option now works, -ghg- */ /* v0.28, 89.0430, -lsdh options added, jm Forgeas */ /* v0.27, 88.1113, original coding by Gauthier Groult */ /* */ #include #include #include #include #include #include #include #include "iff2c.h" struct GfxBase *GfxBase; VOID main(argc, argv) UBYTE argc, **argv; { UBYTE arg=1, flags = PRINT_COMMENTS | PRINT_IMAGE | COMPUTE_ONOFF | STATIC_DATA | PRINT_DATA | LATTICE_CHIP; LONG file; IFFP iffp = NO_FILE; ILBMFrame iFrame; struct BitMap bitmap; if (!(GfxBase = (struct GfxBase *)OpenLibrary("graphics.library", 0))) exit(1); if (argc==1) { fputs("Usage: Iff2C [-cidpslh] [...]\n", stderr); fputs(" -c: switches comment output, default on\n", stderr); fputs(" -i: switches image structure output, default on\n", stderr); fputs(" -d: switches data words output, default on\n", stderr); fputs(" -p: plane on/off computation, default on\n", stderr); fputs(" -s: switches 'static' image data, default on\n", stderr); fputs(" -l: switches Lattice keyword 'chip', default on\n", stderr); fputs(" -h: header and trailer words (sprite), default off\n", stderr); fputs("Iff2C v0.30, by Gauthier Groult & Jm Forgeas, 89.0512, pd\n", stderr); goto CLEANUP; } while (arg