| 437 |
|
register int n; |
| 438 |
|
int suffix; |
| 439 |
|
|
| 440 |
< |
suffix = n = strlen(orig); /* find start of suffix */ |
| 441 |
< |
if ((cp = rindex(orig, '.')) != NULL) |
| 442 |
< |
suffix = cp - orig; |
| 440 |
> |
n = 0; cp = orig; suffix = -1; /* suffix position, length */ |
| 441 |
> |
while (*cp) { |
| 442 |
> |
if (*cp == '.') suffix = n; |
| 443 |
> |
else if (ISDIRSEP(*cp)) suffix = -1; |
| 444 |
> |
cp++; n++; |
| 445 |
> |
} |
| 446 |
> |
if (suffix == -1) suffix = n; |
| 447 |
|
if ((cp = bmalloc(n+2)) == NULL) |
| 448 |
|
syserr(progname); |
| 449 |
|
strncpy(cp, orig, suffix); |
| 832 |
|
} |
| 833 |
|
op = addarg(op, "-pt .08"); |
| 834 |
|
if (vbool(PENUMBRAS)) |
| 835 |
< |
op = addarg(op, "-ds .2 -dj .35"); |
| 835 |
> |
op = addarg(op, "-ds .2 -dj .5"); |
| 836 |
|
else |
| 837 |
|
op = addarg(op, "-ds .3"); |
| 838 |
|
op = addarg(op, "-dt .1 -dc .5 -dr 1 -sj .7 -st .1"); |
| 1223 |
|
sprintf(combuf, "rview %s%s -R %s ", vw, opts, rifname); |
| 1224 |
|
if (rvdevice != NULL) |
| 1225 |
|
sprintf(combuf+strlen(combuf), "-o %s ", rvdevice); |
| 1226 |
+ |
if (vdef(EXPOSURE)) |
| 1227 |
+ |
sprintf(combuf+strlen(combuf), "-pe %s ", vval(EXPOSURE)); |
| 1228 |
|
strcat(combuf, oct1name); |
| 1229 |
|
if (runcom(combuf)) { /* run it */ |
| 1230 |
|
fprintf(stderr, "%s: error running rview\n", progname); |
| 1305 |
|
} |
| 1306 |
|
sprintf(combuf, "rpict%s %s %s%s %s > %s", |
| 1307 |
|
rep, vw, res, opts, |
| 1308 |
< |
oct1name, rawfile); |
| 1308 |
> |
oct1name, rawfile); |
| 1309 |
|
} |
| 1310 |
|
if (runcom(combuf)) { /* run rpict */ |
| 1311 |
|
fprintf(stderr, "%s: error rendering view %s\n", |