283 |
|
void *p |
284 |
|
) |
285 |
|
{ |
286 |
< |
char fmt[32]; |
286 |
> |
char fmt[MAXFMTLEN]; |
287 |
|
|
288 |
|
if (isexpos(s)) |
289 |
|
exposure *= exposval(s); |
290 |
|
else if (formatval(fmt, s)) |
291 |
< |
wrongformat = strcmp(fmt, COLRFMT); |
292 |
< |
else if (isview(s) && sscanview(&ourview, s) > 0) |
293 |
< |
gotview++; |
291 |
> |
wrongformat = strcmp(fmt, COLRFMT) && strcmp(fmt, SPECFMT); |
292 |
> |
else if (isview(s)) |
293 |
> |
gotview += sscanview(&ourview, s); |
294 |
> |
else if (isncomp(s)) |
295 |
> |
NCSAMP = ncompval(s); |
296 |
> |
else if (iswlsplit(s)) |
297 |
> |
wlsplitval(WLPART, s); |
298 |
|
return(0); |
299 |
|
} |
300 |
|
|
425 |
|
register int es; |
426 |
|
int cs; |
427 |
|
|
428 |
< |
if ( (es = err != NULL) ) |
428 |
> |
if ( (es = (err != NULL)) ) |
429 |
|
fprintf(stderr, "%s: %s: %s\n", progname, |
430 |
|
fname==NULL?"<stdin>":fname, err); |
431 |
|
if (thedisplay != NULL) |
1073 |
|
tmGlobal = tmInit(flags, stdprims, gamcor); |
1074 |
|
if (tmGlobal == NULL) |
1075 |
|
goto memerr; |
1076 |
< |
if (tmSetSpace(tmGlobal, stdprims, WHTEFFICACY/exposure, NULL)) |
1076 |
> |
if (tmSetSpace(tmGlobal, stdprims, WHTEFFICACY/exposure)) |
1077 |
|
goto tmerr; |
1078 |
|
/* compute picture histogram */ |
1079 |
|
for (y = 0; y < ymax; y++) { |
1405 |
|
} else if (scanpos != NULL && scanpos[y] == -1) |
1406 |
|
scanpos[y] = ftell(fin); |
1407 |
|
|
1408 |
< |
if (freadcolrs(scanline, xmax, fin) < 0) { |
1408 |
> |
if (fread2colrs(scanline, xmax, fin, NCSAMP, WLPART) < 0) { |
1409 |
|
fprintf(stderr, "%s: %s: unfinished picture\n", |
1410 |
|
progname, fname==NULL?"<stdin>":fname); |
1411 |
|
trunced = y; |