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

Comparing ray/src/rt/m_mirror.c (file contents):
Revision 2.22 by greg, Tue Jan 21 21:31:58 2020 UTC vs.
Revision 2.23 by greg, Wed Nov 15 18:02:53 2023 UTC

# Line 35 | Line 35 | m_mirror(                      /* shade mirrored ray */
35          RAY  *r
36   )
37   {
38 <        COLOR  mcolor;
38 >        SCOLOR  mcolor;
39          RAY  nr;
40          int  rpure = 1;
41          int  i;
# Line 65 | Line 65 | m_mirror(                      /* shade mirrored ray */
65                                          /* get modifiers */
66          raytexture(r, m->omod);
67                                          /* assign material color */
68 <        setcolor(mcolor, m->oargs.farg[0],
68 >        setscolor(mcolor, m->oargs.farg[0],
69                          m->oargs.farg[1],
70                          m->oargs.farg[2]);
71 <        multcolor(mcolor, r->pcol);
71 >        smultscolor(mcolor, r->pcol);
72                                          /* compute reflected ray */
73          if (r->rsrc >= 0) {                     /* relayed light source */
74                  rayorigin(&nr, REFLECTED, r, mcolor);
# Line 97 | Line 97 | m_mirror(                      /* shade mirrored ray */
97          }
98          checknorm(nr.rdir);
99          rayvalue(&nr);
100 <        multcolor(nr.rcol, nr.rcoef);
101 <        copycolor(r->mcol, nr.rcol);
102 <        addcolor(r->rcol, nr.rcol);
100 >        smultscolor(nr.rcol, nr.rcoef);
101 >        copyscolor(r->mcol, nr.rcol);
102 >        saddscolor(r->rcol, nr.rcol);
103          r->rmt = r->rot;
104          if (rpure && r->ro != NULL && isflat(r->ro->otype))
105                  r->rmt += raydistance(&nr);

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines