9 |
|
#include "standard.h" |
10 |
|
#include "view.h" |
11 |
|
|
12 |
< |
extern int putf(), putd(), puta(); |
12 |
> |
typedef void putfunc(FVECT ro, FVECT rd); |
13 |
> |
static putfunc puta; |
14 |
> |
static putfunc putf; |
15 |
> |
static putfunc putd; |
16 |
> |
static void pix2rays(FILE *fp); |
17 |
> |
static void putrays(void); |
18 |
|
|
19 |
< |
int (*putr)() = puta; |
19 |
> |
static putfunc *putr = puta; |
20 |
|
|
21 |
|
VIEW vw = STDVIEW; |
22 |
|
|
31 |
|
char *progname; |
32 |
|
|
33 |
|
|
34 |
< |
main(argc, argv) |
35 |
< |
int argc; |
36 |
< |
char *argv[]; |
34 |
> |
int |
35 |
> |
main( |
36 |
> |
int argc, |
37 |
> |
char *argv[] |
38 |
> |
) |
39 |
|
{ |
40 |
|
char *err; |
41 |
|
int rval, getdim = 0; |
147 |
|
} |
148 |
|
|
149 |
|
|
150 |
< |
pix2rays(FILE *fp) |
150 |
> |
static void |
151 |
> |
pix2rays( |
152 |
> |
FILE *fp |
153 |
> |
) |
154 |
|
{ |
155 |
|
static FVECT rorg, rdir; |
156 |
|
float zval; |
200 |
|
} |
201 |
|
|
202 |
|
|
203 |
< |
putrays() |
203 |
> |
static void |
204 |
> |
putrays(void) |
205 |
|
{ |
206 |
|
static RREAL loc[2]; |
207 |
|
static FVECT rorg, rdir; |
208 |
< |
float *zbuf; |
208 |
> |
float *zbuf = NULL; |
209 |
|
int sc; |
210 |
|
double d; |
211 |
|
register int si, i; |
248 |
|
} |
249 |
|
|
250 |
|
|
251 |
< |
puta(ro, rd) /* put out ray in ASCII format */ |
252 |
< |
FVECT ro, rd; |
251 |
> |
static void |
252 |
> |
puta( /* put out ray in ASCII format */ |
253 |
> |
FVECT ro, |
254 |
> |
FVECT rd |
255 |
> |
) |
256 |
|
{ |
257 |
|
printf("%.5e %.5e %.5e %.5e %.5e %.5e\n", |
258 |
|
ro[0], ro[1], ro[2], |
260 |
|
} |
261 |
|
|
262 |
|
|
263 |
< |
putf(ro, rd) /* put out ray in float format */ |
264 |
< |
FVECT ro, rd; |
263 |
> |
static void |
264 |
> |
putf( /* put out ray in float format */ |
265 |
> |
FVECT ro, |
266 |
> |
FVECT rd |
267 |
> |
) |
268 |
|
{ |
269 |
|
float v[6]; |
270 |
|
|
274 |
|
} |
275 |
|
|
276 |
|
|
277 |
< |
putd(ro, rd) /* put out ray in double format */ |
278 |
< |
FVECT ro, rd; |
277 |
> |
static void |
278 |
> |
putd( /* put out ray in double format */ |
279 |
> |
FVECT ro, |
280 |
> |
FVECT rd |
281 |
> |
) |
282 |
|
{ |
283 |
|
double v[6]; |
284 |
|
|