7 |
|
* 1/4/89 |
8 |
|
*/ |
9 |
|
|
10 |
< |
#include "standard.h" |
10 |
> |
#include "platform.h" |
11 |
> |
#include "rtprocess.h" |
12 |
> |
#include "rterror.h" |
13 |
|
#include "color.h" |
14 |
|
#include "calcomp.h" |
15 |
|
#include "view.h" |
70 |
|
int wrongformat = 0; |
71 |
|
int gotview; |
72 |
|
|
71 |
– |
FILE *popen(); |
73 |
|
|
74 |
|
extern char *emalloc(); |
75 |
|
|
109 |
|
for (nfiles = 0; nfiles < MAXINP; nfiles++) { |
110 |
|
setcolor(input[nfiles].coef, 1.0, 1.0, 1.0); |
111 |
|
setcolor(input[nfiles].expos, 1.0, 1.0, 1.0); |
112 |
< |
copystruct(&input[nfiles].vw, &stdview); |
112 |
> |
input[nfiles].vw = stdview; |
113 |
|
input[nfiles].pa = 1.0; |
114 |
|
} |
115 |
|
nfiles = 0; |
312 |
|
|
313 |
|
init() /* perform final setup */ |
314 |
|
{ |
315 |
< |
double l_colin(), l_expos(), l_pixaspect(), l_ray(), l_psize(); |
315 |
> |
double l_colin(char *), l_expos(char *), l_pixaspect(char *), |
316 |
> |
l_ray(char *), l_psize(char *); |
317 |
|
register int i; |
318 |
|
/* define constants */ |
319 |
|
varset("PI", ':', PI); |
447 |
|
|
448 |
|
|
449 |
|
double |
450 |
< |
l_pixaspect() /* return pixel aspect ratio */ |
450 |
> |
l_pixaspect(char *nm) /* return pixel aspect ratio */ |
451 |
|
{ |
452 |
|
register int fn; |
453 |
|
|
519 |
|
static unsigned long ltick[MAXINP]; |
520 |
|
static FVECT lorg[MAXINP], ldir[MAXINP]; |
521 |
|
static double ldist[MAXINP]; |
522 |
< |
FLOAT loc[2]; |
522 |
> |
RREAL loc[2]; |
523 |
|
int fn; |
524 |
|
register int i; |
525 |
|
|
552 |
|
|
553 |
|
|
554 |
|
double |
555 |
< |
l_psize() /* compute pixel size in steradians */ |
555 |
> |
l_psize(char *nm) /* compute pixel size in steradians */ |
556 |
|
{ |
557 |
|
static unsigned long ltick[MAXINP]; |
558 |
|
static double psize[MAXINP]; |
559 |
|
FVECT dir0, org, dirx, diry; |
560 |
< |
FLOAT locx[2], locy[2]; |
560 |
> |
RREAL locx[2], locy[2]; |
561 |
|
double d; |
562 |
|
int fn; |
563 |
|
register int i; |
597 |
|
} |
598 |
|
|
599 |
|
|
600 |
< |
void |
601 |
< |
wputs(msg) |
600 |
< |
char *msg; |
600 |
> |
extern void |
601 |
> |
wputs(char *msg) |
602 |
|
{ |
603 |
|
if (!nowarn) |
604 |
|
eputs(msg); |
605 |
|
} |
606 |
|
|
607 |
|
|
608 |
< |
void |
609 |
< |
eputs(msg) |
609 |
< |
char *msg; |
608 |
> |
extern void |
609 |
> |
eputs(char *msg) |
610 |
|
{ |
611 |
|
fputs(msg, stderr); |
612 |
|
} |
613 |
|
|
614 |
|
|
615 |
< |
void |
616 |
< |
quit(code) /* exit gracefully */ |
617 |
< |
int code; |
615 |
> |
extern void |
616 |
> |
quit(int code) /* exit gracefully */ |
617 |
|
{ |
618 |
|
register int i; |
619 |
|
/* close input files */ |