61 |
|
|
62 |
|
if (r->rod < 0.0) /* reorient if necessary */ |
63 |
|
flipsurface(r); |
64 |
– |
r->rt = r->rot; /* default ray length */ |
64 |
|
transtest = 0; |
65 |
|
/* get modifiers */ |
66 |
|
raytexture(r, m->omod); |
83 |
|
} |
84 |
|
/* transmitted ray */ |
85 |
|
if (rayorigin(&p, r, TRANS, bright(trans)) == 0) { |
86 |
< |
if (DOT(r->pert,r->pert) > FTINY*FTINY) { |
86 |
> |
if (!(r->crtype & SHADOW) && |
87 |
> |
DOT(r->pert,r->pert) > FTINY*FTINY) { |
88 |
|
for (i = 0; i < 3; i++) /* perturb direction */ |
89 |
|
p.rdir[i] = r->rdir[i] - r->pert[i]/RINDEX; |
90 |
|
normalize(p.rdir); |
91 |
< |
} else |
91 |
> |
} else { |
92 |
> |
VCOPY(p.rdir, r->rdir); |
93 |
|
transtest = 2; |
94 |
+ |
} |
95 |
|
rayvalue(&p); |
96 |
|
multcolor(p.rcol, r->pcol); /* modify */ |
97 |
|
multcolor(p.rcol, trans); |