Mercurial > hg > wm
comparison Meerwald/wm_kim_d.c @ 8:f83ef905a63d
fixing many warnings
increase capacity for coordinates in bruyn
fix some uninit. variables
| author | Peter Meerwald <pmeerw@cosy.sbg.ac.at> |
|---|---|
| date | Tue, 22 Apr 2008 13:36:05 +0200 |
| parents | acb6967ee76d |
| children | ad1d224896c5 |
comparison
equal
deleted
inserted
replaced
| 7:2b350281f8b0 | 8:f83ef905a63d |
|---|---|
| 65 char output_name[MAXPATHLEN] = "(stdout)"; | 65 char output_name[MAXPATHLEN] = "(stdout)"; |
| 66 char input_name[MAXPATHLEN] = "(stdin)"; | 66 char input_name[MAXPATHLEN] = "(stdin)"; |
| 67 char orig_name[MAXPATHLEN]; | 67 char orig_name[MAXPATHLEN]; |
| 68 | 68 |
| 69 int c, w; | 69 int c, w; |
| 70 int i; | |
| 71 int n = 0; | 70 int n = 0; |
| 72 int method = -1; | 71 int method = -1; |
| 73 int filter = 0; | 72 int filter = 0; |
| 74 char filter_name[MAXPATHLEN] = ""; | 73 char filter_name[MAXPATHLEN] = ""; |
| 75 | 74 |
| 80 int in_rows, in_cols, in_format; | 79 int in_rows, in_cols, in_format; |
| 81 gray in_maxval; | 80 gray in_maxval; |
| 82 int orig_rows, orig_cols, orig_format; | 81 int orig_rows, orig_cols, orig_format; |
| 83 gray orig_maxval; | 82 gray orig_maxval; |
| 84 int rows, cols; | 83 int rows, cols; |
| 85 int row, col; | 84 int row; |
| 86 | 85 |
| 87 double *watermark; | 86 double *watermark; |
| 88 | 87 |
| 89 Image_tree input_dwts, orig_dwts, p, q; | 88 Image_tree input_dwts, orig_dwts, p, q; |
| 90 | 89 |
| 175 if (argc > 1) { | 174 if (argc > 1) { |
| 176 usage(); | 175 usage(); |
| 177 exit(1); | 176 exit(1); |
| 178 } | 177 } |
| 179 | 178 |
| 180 if (argc == 1 && *argv[0] != '-') | 179 if (argc == 1 && *argv[0] != '-') { |
| 181 if ((in = fopen(argv[0], "rb")) == NULL) { | 180 if ((in = fopen(argv[0], "rb")) == NULL) { |
| 182 fprintf(stderr, "%s: unable to open input file %s\n", progname, argv[0]); | 181 fprintf(stderr, "%s: unable to open input file %s\n", progname, argv[0]); |
| 183 exit(1); | 182 exit(1); |
| 184 } | 183 } |
| 185 else | 184 else |
| 186 strcpy(input_name, argv[0]); | 185 strcpy(input_name, argv[0]); |
| 187 | 186 } |
| 187 | |
| 188 if (!orig) { | 188 if (!orig) { |
| 189 fprintf(stderr, "%s: original image file not specified, use -i file option\n", progname); | 189 fprintf(stderr, "%s: original image file not specified, use -i file option\n", progname); |
| 190 exit(1); | 190 exit(1); |
| 191 } | 191 } |
| 192 | 192 |
