Lines Matching defs:file
1 /* setupdialog : converts a RAW image file into the c structure that the
18 printf("\nusage: setupdialog -i <image file> -oi <image output> -n <numbers file> -on <numbers output>\n");
20 printf("\nYou can supply a panic image file, a numbers file, or both. Input files\n");
33 char *file = NULL, *ptr, *out = NULL, *numsfile = NULL, *numsout = NULL;
52 if (strcmp(argv[next], "-i") == 0) // image file (RAW/PICT?)
53 file = argv[++next];
54 else if (strcmp(argv[next], "-n") == 0) // numbers/chars image file (RAW)
56 else if (strcmp(argv[next], "-oi") == 0) // output file for image
58 else if (strcmp(argv[next], "-on") == 0) // output file for numbers
70 if (!(numsfile || file)) {
76 printf("\nNo numbers file to process\n");
87 if( file == NULL) {
88 printf("\nNo image file to process\n");
92 stream = fopen(file, "r");
98 printf("\nReading image file...\n");
108 printf("Invalid image file header (width, height, or depth is 0)\n");
121 filePos = 0; // position in the file we're writing out
148 // now, generate the c file
155 printf("couldn't open out file.. bailing\n");
161 fprintf( out_stream, "/* generated c file */\n\n");
203 The image file is read row by row, so the individual characters
223 printf("\nReading numbers file...\n");
232 printf("Invalid numbers file header (width, height, or depth is 0)\n");
279 // now, generate the c file
290 fprintf( out_stream, " /* generated c file */\n\n");