--- ray/src/rt/ray.h 2009/12/12 00:03:42 2.30 +++ ray/src/rt/ray.h 2011/04/06 00:14:26 2.36 @@ -1,4 +1,4 @@ -/* RCSid $Id: ray.h,v 2.30 2009/12/12 00:03:42 greg Exp $ */ +/* RCSid $Id: ray.h,v 2.36 2011/04/06 00:14:26 greg Exp $ */ /* * ray.h - header file for routines using rays. */ @@ -76,8 +76,8 @@ extern char VersionID[]; /* Radiance version ID strin extern CUBE thescene; /* our scene */ extern OBJECT nsceneobjs; /* number of objects in our scene */ -extern unsigned long raynum; /* next ray ID */ -extern unsigned long nrays; /* total rays traced so far */ +extern RNUMBER raynum; /* next ray ID */ +extern RNUMBER nrays; /* total rays traced so far */ extern OBJREC Lamb; /* a Lambertian surface */ extern OBJREC Aftplane; /* aft clipping object */ @@ -195,12 +195,16 @@ extern void ray_restore(RAYPARAMS *rp); extern void ray_defaults(RAYPARAMS *rp); /* defined in raypcalls.c */ extern void ray_pinit(char *otnm, int nproc); -extern void ray_psend(RAY *r); +extern int ray_psend(RAY *r); extern int ray_pqueue(RAY *r); extern int ray_presult(RAY *r, int poll); extern void ray_pdone(int freall); extern void ray_popen(int nadd); extern void ray_pclose(int nsub); + /* defined in ray_fifo.c */ +extern int (*ray_fifo_out)(RAY *r); +extern int ray_fifo_in(RAY *r); +extern int ray_fifo_flush(void); /* defined in raytrace.c */ extern int rayorigin(RAY *r, int rt, const RAY *ro, const COLOR rc); extern void rayclear(RAY *r); @@ -212,7 +216,7 @@ extern int rayshade(RAY *r, int mod); extern void rayparticipate(RAY *r); extern void raytexture(RAY *r, OBJECT mod); extern int raymixture(RAY *r, OBJECT fore, OBJECT back, double coef); -extern void raycontrib(double rc[3], const RAY *r, int flags); +extern void raycontrib(RREAL rc[3], const RAY *r, int flags); extern double raydist(const RAY *r, int flags); extern double raynormal(FVECT norm, RAY *r); extern void newrayxf(RAY *r); @@ -228,11 +232,16 @@ extern void init_drawsources(int rad); /* defined in rt/initotypes.c */ extern void initotypes(void); /* module main procedures */ -extern void rtrace(char *fname); -extern char * formstr(int f); +extern void rtrace(char *fname, int nproc); +extern char *formstr(int f); extern void rview(void); extern void rpict(int seq, char *pout, char *zout, char *prvr); +#ifdef __FAST_MATH__ +#define checknorm(vn) normalize(vn) +#else +#define checknorm(vn) 1.0 +#endif #ifdef __cplusplus }