--- ray/src/rt/o_cone.c 2003/02/25 02:47:22 2.3 +++ ray/src/rt/o_cone.c 2004/03/30 16:13:01 2.5 @@ -1,5 +1,5 @@ #ifndef lint -static const char RCSid[] = "$Id: o_cone.c,v 2.3 2003/02/25 02:47:22 greg Exp $"; +static const char RCSid[] = "$Id: o_cone.c,v 2.5 2004/03/30 16:13:01 schorsch Exp $"; #endif /* * o_cone.c - routine to determine ray intersection with cones. @@ -8,15 +8,16 @@ static const char RCSid[] = "$Id: o_cone.c,v 2.3 2003/ #include "copyright.h" #include "ray.h" - #include "otypes.h" - +#include "rtotypes.h" #include "cone.h" -o_cone(o, r) /* intersect ray with cone */ -OBJREC *o; -register RAY *r; +extern int +o_cone( /* intersect ray with cone */ + OBJREC *o, + register RAY *r +) { FVECT rox, rdx; double a, b, c; @@ -127,6 +128,8 @@ register RAY *r; r->ron[i] = (co->al*r->ron[i] - c*co->ad[i]) /co->sl; r->rod = -DOT(r->rdir, r->ron); + r->pert[0] = r->pert[1] = r->pert[2] = 0.0; + r->uv[0] = r->uv[1] = 0.0; r->rox = NULL; return(1); /* good */ }