| 134 |
|
char *expcomp = NULL; |
| 135 |
|
int i, an, rval; |
| 136 |
|
|
| 137 |
+ |
SET_DEFAULT_BINARY(); |
| 138 |
+ |
SET_FILE_BINARY(stdout); |
| 139 |
+ |
|
| 140 |
|
progname = argv[0]; |
| 141 |
|
|
| 142 |
|
for (an = 1; an < argc && argv[an][0] == '-'; an++) { |
| 394 |
|
{ |
| 395 |
|
char linebuf[256]; |
| 396 |
|
char *err; |
| 397 |
< |
register int i; |
| 397 |
> |
int i; |
| 398 |
|
|
| 399 |
|
if (fp != NULL) { |
| 400 |
|
do /* get new view */ |
| 431 |
|
static void |
| 432 |
|
compavgview(void) /* compute average view */ |
| 433 |
|
{ |
| 434 |
< |
register int i; |
| 434 |
> |
int i; |
| 435 |
|
double f; |
| 436 |
|
|
| 437 |
|
if (nvavg < 2) |
| 499 |
|
syserror(progname); |
| 500 |
|
if ((zfd = open(zspec, O_RDONLY)) == -1) { |
| 501 |
|
double zvalue; |
| 502 |
< |
register int x; |
| 502 |
> |
int x; |
| 503 |
|
if (!isflt(zspec) || (zvalue = atof(zspec)) <= 0.0) |
| 504 |
|
syserror(zspec); |
| 505 |
|
for (x = scanlen(&tresolu); x-- > 0; ) |
| 558 |
|
|
| 559 |
|
static int |
| 560 |
|
pixform( /* compute view1 to view2 matrix */ |
| 561 |
< |
register MAT4 xfmat, |
| 562 |
< |
register VIEW *vw1, |
| 563 |
< |
register VIEW *vw2 |
| 561 |
> |
MAT4 xfmat, |
| 562 |
> |
VIEW *vw1, |
| 563 |
> |
VIEW *vw2 |
| 564 |
|
) |
| 565 |
|
{ |
| 566 |
< |
double m4t[4][4]; |
| 566 |
> |
MAT4 m4t; |
| 567 |
|
|
| 568 |
|
if ((vw1->type != VT_PER) & (vw1->type != VT_PAR)) |
| 569 |
|
return(0); |
| 612 |
|
FVECT pos; |
| 613 |
|
struct position lastx, newpos; |
| 614 |
|
double wt; |
| 615 |
< |
register int x; |
| 615 |
> |
int x; |
| 616 |
|
|
| 617 |
|
lastx.z = 0; |
| 618 |
|
for (x = xl->max; x >= xl->min; x--) { |
| 650 |
|
int l1, l2, c1, c2; /* side lengths and counters */ |
| 651 |
|
int p1isy; /* p0p1 along y? */ |
| 652 |
|
int x1, y1; /* p1 position */ |
| 653 |
< |
register int x, y; /* final position */ |
| 653 |
> |
int x, y; /* final position */ |
| 654 |
|
|
| 655 |
|
/* compute vector p0p1 */ |
| 656 |
|
if (fillo&F_FORE && ABS(p1->z-p0->z) <= zt) { |
| 717 |
|
|
| 718 |
|
static double |
| 719 |
|
movepixel( /* reposition image point */ |
| 720 |
< |
register FVECT pos |
| 720 |
> |
FVECT pos |
| 721 |
|
) |
| 722 |
|
{ |
| 723 |
|
FVECT pt, tdir, odir; |
| 783 |
|
|
| 784 |
|
static int |
| 785 |
|
getperim( /* compute overlapping image area */ |
| 786 |
< |
register struct bound *xl, |
| 786 |
> |
struct bound *xl, |
| 787 |
|
struct bound *yl, |
| 788 |
|
float *zline, |
| 789 |
|
int zfd |
| 791 |
|
{ |
| 792 |
|
int step; |
| 793 |
|
FVECT pos; |
| 794 |
< |
register int x, y; |
| 794 |
> |
int x, y; |
| 795 |
|
/* set up step size */ |
| 796 |
|
if (scanlen(&tresolu) < numscans(&tresolu)) |
| 797 |
|
step = scanlen(&tresolu)/NSTEPS; |
| 875 |
|
{ |
| 876 |
|
int *yback, xback; |
| 877 |
|
int y; |
| 878 |
< |
register int x, i; |
| 878 |
> |
int x, i; |
| 879 |
|
/* get back buffer */ |
| 880 |
|
yback = (int *)malloc(hresolu*sizeof(int)); |
| 881 |
|
if (yback == NULL) |
| 982 |
|
fillfunc_t *fill |
| 983 |
|
) |
| 984 |
|
{ |
| 985 |
< |
register int x, y; |
| 985 |
> |
int x, y; |
| 986 |
|
|
| 987 |
|
for (y = 0; y < vresolu; y++) |
| 988 |
|
for (x = 0; x < hresolu; x++) |
| 996 |
|
static int |
| 997 |
|
clipaft(void) /* perform aft clipping as indicated */ |
| 998 |
|
{ |
| 999 |
< |
register int x, y; |
| 999 |
> |
int x, y; |
| 1000 |
|
int adjtest = (ourview.type == VT_PER) & zisnorm; |
| 1001 |
|
double tstdist; |
| 1002 |
|
double yzn2, vx; |
| 1035 |
|
{ |
| 1036 |
|
COLOR cval; |
| 1037 |
|
double d; |
| 1038 |
< |
register int i; |
| 1038 |
> |
int i; |
| 1039 |
|
|
| 1040 |
|
if (!blurring) |
| 1041 |
|
return(0); |
| 1075 |
|
writepicture(void) /* write out picture (alters buffer) */ |
| 1076 |
|
{ |
| 1077 |
|
int y; |
| 1078 |
< |
register int x; |
| 1078 |
> |
int x; |
| 1079 |
|
double d; |
| 1080 |
|
|
| 1081 |
|
fprtresolu(hresolu, vresolu, stdout); |
| 1118 |
|
for (y = vresolu-1; y >= 0; y--) { |
| 1119 |
|
if (donorm) { |
| 1120 |
|
double vx, yzn2, d; |
| 1121 |
< |
register int x; |
| 1121 |
> |
int x; |
| 1122 |
|
yzn2 = (y+.5)/vresolu + ourview.voff - .5; |
| 1123 |
|
yzn2 = 1. + yzn2*yzn2*ourview.vn2; |
| 1124 |
|
for (x = 0; x < hresolu; x++) { |
| 1162 |
|
char combuf[512]; |
| 1163 |
|
char *argv[64]; |
| 1164 |
|
int rval; |
| 1165 |
< |
register char **wp, *cp; |
| 1165 |
> |
char **wp, *cp; |
| 1166 |
|
|
| 1167 |
|
if (PDesc.running) { |
| 1168 |
|
fprintf(stderr, "%s: too many calculations\n", progname); |
| 1226 |
|
{ |
| 1227 |
|
FVECT orig, dir; |
| 1228 |
|
float fbuf[6*(PACKSIZ+1)]; |
| 1229 |
< |
register float *fbp; |
| 1230 |
< |
register int i; |
| 1229 |
> |
float *fbp; |
| 1230 |
> |
int i; |
| 1231 |
|
double vx, vy; |
| 1232 |
|
|
| 1233 |
|
if (queuesiz == 0) |