Mercurial > hg > wm
comparison Meerwald/wm_kim_e.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 |
---|---|
56 char output_name[MAXPATHLEN] = "(stdout)"; | 56 char output_name[MAXPATHLEN] = "(stdout)"; |
57 char input_name[MAXPATHLEN] = "(stdin)"; | 57 char input_name[MAXPATHLEN] = "(stdin)"; |
58 char signature_name[MAXPATHLEN]; | 58 char signature_name[MAXPATHLEN]; |
59 | 59 |
60 int i, c, w; | 60 int i, c, w; |
61 int row, col; | 61 int row; |
62 | 62 |
63 int n; | 63 int n; |
64 | 64 |
65 double alpha_detail = 0.0; | 65 double alpha_detail = 0.0; |
66 double alpha_approx = 0.0; | 66 double alpha_approx = 0.0; |
75 | 75 |
76 gray **image; | 76 gray **image; |
77 Image_tree p, dwts; | 77 Image_tree p, dwts; |
78 | 78 |
79 gray maxval; | 79 gray maxval; |
80 int rows, cols, colors, format; | 80 int rows, cols, format; |
81 | 81 |
82 double *watermark; | 82 double *watermark; |
83 | 83 |
84 progname = argv[0]; | 84 progname = argv[0]; |
85 | 85 |
159 if (argc > 1) { | 159 if (argc > 1) { |
160 usage(); | 160 usage(); |
161 exit(1); | 161 exit(1); |
162 } | 162 } |
163 | 163 |
164 if (argc == 1 && *argv[0] != '-') | 164 if (argc == 1 && *argv[0] != '-') { |
165 if ((in = fopen(argv[0], "rb")) == NULL) { | 165 if ((in = fopen(argv[0], "rb")) == NULL) { |
166 fprintf(stderr, "%s: unable to open input file %s\n", progname, argv[0]); | 166 fprintf(stderr, "%s: unable to open input file %s\n", progname, argv[0]); |
167 exit(1); | 167 exit(1); |
168 } | 168 } |
169 else | 169 else |
170 strcpy(input_name, argv[0]); | 170 strcpy(input_name, argv[0]); |
171 | 171 } |
172 | |
172 if (sig) { | 173 if (sig) { |
173 char line[32]; | 174 char line[32]; |
174 fgets(line, sizeof(line), sig); | 175 fgets(line, sizeof(line), sig); |
175 if (strspn(line, "KISG") >= 4) { | 176 if (strspn(line, "KISG") >= 4) { |
176 fscanf(sig, "%d\n", &n); | 177 fscanf(sig, "%d\n", &n); |