| 105 |
|
|
| 106 |
|
long scenedate; /* date of latest scene or object file */ |
| 107 |
|
long octreedate; /* date of octree */ |
| 108 |
+ |
long matdate; /* date of latest material file */ |
| 109 |
|
|
| 110 |
|
int explicate = 0; /* explicate variables */ |
| 111 |
|
int silent = 0; /* do work silently */ |
| 424 |
|
vnam(OCTREE), vnam(SCENE)); |
| 425 |
|
exit(1); |
| 426 |
|
} |
| 427 |
+ |
matdate = -1; |
| 428 |
+ |
if (vdef(MATERIAL)) |
| 429 |
+ |
matdate = checklast(vval(MATERIAL)); |
| 430 |
|
} |
| 431 |
|
|
| 432 |
|
|
| 565 |
|
{ |
| 566 |
|
long afdate; |
| 567 |
|
|
| 568 |
< |
if (vdef(AMBFILE)) { |
| 569 |
< |
afdate = fdate(vval(AMBFILE)); |
| 570 |
< |
if (afdate >= 0 & octreedate > afdate) |
| 571 |
< |
rmfile(vval(AMBFILE)); |
| 572 |
< |
} |
| 568 |
> |
if (!vdef(AMBFILE)) |
| 569 |
> |
return; |
| 570 |
> |
if ((afdate = fdate(vval(AMBFILE))) < 0) |
| 571 |
> |
return; |
| 572 |
> |
if (octreedate > afdate | matdate > afdate) |
| 573 |
> |
rmfile(vval(AMBFILE)); |
| 574 |
|
} |
| 575 |
|
|
| 576 |
|
|
| 823 |
|
po = addarg(po, "-1 -e"); |
| 824 |
|
po = addarg(po, vval(EXPOSURE)); |
| 825 |
|
} |
| 826 |
< |
if (vscale(QUALITY) == HIGH) |
| 827 |
< |
po = addarg(po, "-r .65"); |
| 826 |
> |
switch (vscale(QUALITY)) { |
| 827 |
> |
case MEDIUM: |
| 828 |
> |
po = addarg(po, "-r 1"); |
| 829 |
> |
break; |
| 830 |
> |
case HIGH: |
| 831 |
> |
po = addarg(po, "-m .15"); |
| 832 |
> |
break; |
| 833 |
> |
} |
| 834 |
|
if (vdef(PFILT)) |
| 835 |
|
po = addarg(po, vval(PFILT)); |
| 836 |
|
} |
| 1063 |
|
sprintf(vs, "%d", vn); |
| 1064 |
|
sprintf(picfile, "%s_%s.pic", vval(PICTURE), vs); |
| 1065 |
|
/* check date on picture */ |
| 1066 |
< |
if (fdate(picfile) > octreedate) |
| 1066 |
> |
if (fdate(picfile) >= octreedate) |
| 1067 |
|
continue; |
| 1068 |
|
/* build rpict command */ |
| 1069 |
|
sprintf(rawfile, "%s_%s.raw", vval(PICTURE), vs); |
| 1070 |
< |
if (fdate(rawfile) > octreedate) /* recover */ |
| 1070 |
> |
if (fdate(rawfile) >= octreedate) /* recover */ |
| 1071 |
|
sprintf(combuf, "rpict%s%s -ro %s %s", |
| 1072 |
|
rep, opts, rawfile, vval(OCTREE)); |
| 1073 |
|
else { |