--- ray/src/cv/rad2mgf.c 1994/09/02 16:21:00 2.6 +++ ray/src/cv/rad2mgf.c 1994/12/12 12:09:28 2.8 @@ -15,6 +15,8 @@ static char SCCSid[] = "$SunId$ LBL"; #include "color.h" #include "lookup.h" +#define PI 3.14159265358979323846 + int o_face(), o_cone(), o_sphere(), o_ring(), o_cylinder(); int o_instance(), o_source(), o_illum(); int o_plastic(), o_metal(), o_glass(), o_mirror(), o_trans(), o_light(); @@ -44,7 +46,7 @@ char VKFMT[] = "%+1.9e %+1.9e %+1.9e"; #define NVERTS 256 -long clock; /* incremented at each vertex request */ +long vclock; /* incremented at each vertex request */ struct vert { long lused; /* when last used (0 if unassigned) */ @@ -345,7 +347,7 @@ FVECT vp; register LUENT *lp; register int i, vndx; - clock++; /* increment counter */ + vclock++; /* increment counter */ mkvkey(vkey, vp); if ((lp = lu_find(&vertab, vkey)) == NULL) goto memerr; @@ -371,7 +373,7 @@ FVECT vp; lp->data = (char *)&vert[vndx]; /* set it */ } else vndx = (struct vert *)lp->data - vert; - vert[vndx].lused = clock; /* record this use */ + vert[vndx].lused = vclock; /* record this use */ sprintf(vname, "v%d", vndx); return(vname); memerr: @@ -728,6 +730,6 @@ register FUNARGS *fa; puts("\tc"); if (d > FTINY) printf("\t\tcxy %.4f %.4f\n", cxyz[0]/d, cxyz[1]/d); - printf("\ted %.4g\n", cxyz[1]*WHTEFFICACY); + printf("\ted %.4g\n", cxyz[1]*(PI*WHTEFFICACY)); return(0); }