ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/radiance/ray/src/rt/normal.c
(Generate patch)

Comparing ray/src/rt/normal.c (file contents):
Revision 1.4 by greg, Wed Oct 18 09:01:36 1989 UTC vs.
Revision 1.5 by greg, Tue Mar 27 11:40:02 1990 UTC

# Line 156 | Line 156 | register RAY  *r;
156          raytexture(r, m->omod);
157          nd.pdot = raynormal(nd.pnorm, r);       /* perturb normal */
158          multcolor(nd.mcolor, r->pcol);          /* modify material color */
159 +        r->rt = r->rot;                         /* default ray length */
160                                                  /* get specular component */
161          nd.rspec = m->oargs.farg[3];
162  
# Line 182 | Line 183 | register RAY  *r;
183                                  rayvalue(&lr);
184                                  multcolor(lr.rcol, nd.scolor);
185                                  addcolor(r->rcol, lr.rcol);
186 +                                if (nd.rspec > 0.5 && m->omod == OVOID)
187 +                                        r->rt = r->rot + lr.rt;
188                          }
189                  }
190          }
# Line 200 | Line 203 | register RAY  *r;
203                          rayvalue(&lr);
204                          scalecolor(lr.rcol, nd.tspec);
205                          addcolor(r->rcol, lr.rcol);
206 +                        if (nd.tspec > .5)
207 +                                r->rt = r->rot + lr.rt;
208                  }
209          }
210          if (r->crtype & SHADOW)                 /* the rest is shadow */

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines