59 |
|
r->pert[0] = r->pert[1] = r->pert[2] = 0.0; |
60 |
|
setcolor(r->pcol, 1.0, 1.0, 1.0); |
61 |
|
setcolor(r->rcol, 0.0, 0.0, 0.0); |
62 |
+ |
r->rt = 0.0; |
63 |
|
return(r->rlvl <= maxdepth && r->rweight >= minweight ? 0 : -1); |
64 |
|
} |
65 |
|
|
96 |
|
VCOPY(tr.rdir, r->rdir); |
97 |
|
rayvalue(&tr); |
98 |
|
copycolor(r->rcol, tr.rcol); |
99 |
+ |
r->rt = r->rot + tr.rt; |
100 |
|
} |
101 |
|
} |
102 |
|
|
212 |
|
* still fraught with problems since reflected rays and similar |
213 |
|
* directions calculated from the surface normal may spawn rays behind |
214 |
|
* the surface. The only solution is to curb textures at high |
215 |
< |
* incidence (Rdot << 1). |
215 |
> |
* incidence (namely, keep DOT(rdir,pert) < Rdot). |
216 |
|
*/ |
217 |
|
|
218 |
|
for (i = 0; i < 3; i++) |