--- ray/src/rt/source.h 1989/02/02 10:41:15 1.1 +++ ray/src/rt/source.h 1989/06/08 09:35:41 1.4 @@ -28,14 +28,24 @@ typedef struct { float prox; /* proximity */ SPOT *s; /* spot */ } sl; /* localized source information */ + long ntests, nhits; /* shadow tests and hits */ OBJREC *so; /* source object */ -} SOURCE; /* light source */ +} SRCREC; /* light source */ -#define MAXSOURCE 512 /* maximum # of sources */ +typedef struct { + FVECT dir; /* source direction */ + float dom; /* domega for source */ + COLOR val; /* contribution */ +} CONTRIB; /* direct contribution */ -extern SOURCE srcval[MAXSOURCE]; /* our source list */ +typedef struct { + int sno; /* source number */ + float brt; /* brightness (for comparison) */ +} CNTPTR; /* contribution pointer */ + +extern SRCREC *source; /* our source list */ extern int nsources; /* the number of sources */ -extern double srcray(); /* ray to source */ +extern double srcray(); /* ray to source */ extern SPOT *makespot(); /* make spotlight */