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

Comparing ray/src/rt/ambient.c (file contents):
Revision 2.44 by gwlarson, Wed Jun 17 13:29:55 1998 UTC vs.
Revision 2.45 by gwlarson, Wed Aug 12 18:16:07 1998 UTC

# Line 377 | Line 377 | COLOR  cr;
377   register AMBVAL  *ap;
378   FVECT  pv, nv;
379   {
380 <        FVECT  v1, v2;
380 >        FVECT  v1;
381          register int  i;
382          double  d;
383  
# Line 386 | Line 386 | FVECT  pv, nv;
386          for (i = 0; i < 3; i++)
387                  d += ap->gpos[i]*(pv[i]-ap->pos[i]);
388                                          /* gradient due to rotation */
389 <        VCOPY(v1, ap->dir);
390 <        fcross(v2, v1, nv);
391 <        d += DOT(ap->gdir, v2);
389 >        VCROSS(v1, ap->dir, nv);
390 >        d += DOT(ap->gdir, v1);
391          if (d <= 0.0) {
392                  setcolor(cr, 0.0, 0.0, 0.0);
393                  return;

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines