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

Comparing ray/src/rt/p_data.c (file contents):
Revision 2.2 by greg, Mon Nov 25 09:50:53 1991 UTC vs.
Revision 2.3 by greg, Tue Dec 22 10:02:58 1992 UTC

# Line 1 | Line 1
1 < /* Copyright (c) 1991 Regents of the University of California */
1 > /* Copyright (c) 1992 Regents of the University of California */
2  
3   #ifndef lint
4   static char SCCSid[] = "$SunId$ LBL";
# Line 117 | Line 117 | RAY  *r;
117                  col[i] = datavalue(dp, pt);
118          }
119          errno = 0;
120 <        setcolor(cval,  funvalue(m->oargs.sarg[0], 3, col),
121 <                        funvalue(m->oargs.sarg[1], 3, col),
122 <                        funvalue(m->oargs.sarg[2], 3, col));
120 >        for (i = 0; i < 3; i++)
121 >                if (fundefined(m->oargs.sarg[i]) < 3)
122 >                        colval(cval,i) = funvalue(m->oargs.sarg[i], 1, col+i);
123 >                else
124 >                        colval(cval,i) = funvalue(m->oargs.sarg[i], 3, col);
125          if (errno)
126                  goto computerr;
127          multcolor(r->pcol, cval);
# Line 154 | Line 156 | RAY  *r;
156          for (i = 0; i < 3; i++)
157                  col[i] = datavalue(dp+i, pt);
158          errno = 0;
159 <        setcolor(cval,  funvalue(m->oargs.sarg[0], 3, col),
160 <                        funvalue(m->oargs.sarg[1], 3, col),
161 <                        funvalue(m->oargs.sarg[2], 3, col));
159 >        for (i = 0; i < 3; i++)
160 >                if (fundefined(m->oargs.sarg[i]) < 3)
161 >                        colval(cval,i) = funvalue(m->oargs.sarg[i], 1, col+i);
162 >                else
163 >                        colval(cval,i) = funvalue(m->oargs.sarg[i], 3, col);
164          if (errno)
165                  goto computerr;
166          multcolor(r->pcol, cval);

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines