66 |
|
if (m->oargs.nfargs != (m->otype==MAT_DIELECTRIC ? 5 : 8)) |
67 |
|
objerror(m, USER, "bad arguments"); |
68 |
|
|
69 |
+ |
r->rt = r->rot; /* just use ray length */ |
70 |
+ |
|
71 |
|
raytexture(r, m->omod); /* get modifiers */ |
72 |
|
|
73 |
|
cos1 = raynormal(dnorm, r); /* cosine of theta1 */ |
137 |
|
multcolor(mcolor, r->pcol); /* modify */ |
138 |
|
scalecolor(p.rcol, trans); |
139 |
|
addcolor(r->rcol, p.rcol); |
138 |
– |
r->rt = r->rot + p.rt; |
140 |
|
} |
141 |
|
} |
142 |
|
} |
152 |
|
|
153 |
|
scalecolor(p.rcol, refl); /* color contribution */ |
154 |
|
addcolor(r->rcol, p.rcol); |
154 |
– |
if (refl > trans) |
155 |
– |
r->rt = r->rot + p.rt; |
155 |
|
} |
156 |
|
|
157 |
|
multcolor(r->rcol, mcolor); /* multiply by transmittance */ |