73 |
|
if ((rdx[2] <= FTINY) & (rdx[2] >= -FTINY)) |
74 |
|
return(0); /* parallel */ |
75 |
|
root[0] = -rox[2]/rdx[2]; |
76 |
< |
if (rayreject(o, r, root[0])) |
76 |
> |
if (rayreject(o, r, root[0], -rdx[2])) |
77 |
|
return(0); /* have better */ |
78 |
|
b = root[0]*rdx[0] + rox[0]; |
79 |
|
c = root[0]*rdx[1] + rox[1]; |
85 |
|
VSUM(r->rop, r->rorg, r->rdir, r->rot); |
86 |
|
VCOPY(r->ron, co->ad); |
87 |
|
r->rod = -rdx[2]; |
88 |
+ |
r->pert[0] = r->pert[1] = r->pert[2] = 0.0; |
89 |
+ |
r->uv[0] = r->uv[1] = 0.0; |
90 |
|
r->rox = NULL; |
91 |
|
return(1); /* good */ |
92 |
|
} |
106 |
|
continue; /* before p0 */ |
107 |
|
if (b > co->al) |
108 |
|
continue; /* after p1 */ |
109 |
< |
if (rayreject(o, r, root[rn])) |
109 |
> |
if (rayreject(o, r, root[rn], 0)) |
110 |
|
break; /* previous hit better */ |
111 |
|
r->ro = o; |
112 |
|
r->rot = root[rn]; |