home *** CD-ROM | disk | FTP | other *** search
- /*
- ** This program will read two bitmap file for exactly the
- ** same format and create a or'd version on standard output
- **
- ** This use is to merge rotated crabs to find the minimal mask
- */
-
- #include <stdio.h>
-
- main(argc, argv)
- int argc;
- char *argv[];
- {
- char c1, c2;
- FILE *file;
-
- if( (file = fopen(argv[1], "r")) == NULL ) {
- fprintf(stderr,"Can't open the argument file\n");
- exit(1);
- }
-
- while( (c1=getchar()) != EOF && (c2=getc(file)) != EOF ) {
- if( c2=='*' )
- c1='*';
- putchar(c1);
- }
- fclose(file);
- return 0;
- }
-