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

Comparing ray/src/common/bsdf_m.c (file contents):
Revision 3.32 by greg, Wed Apr 8 02:41:02 2015 UTC vs.
Revision 3.33 by greg, Wed Apr 8 16:10:47 2015 UTC

# Line 151 | Line 151 | fo_getvec(FVECT v, double ndxr, void *p)
151          for (li = 0; ndx >= ab->lat[li].nphis; li++)
152                  ndx -= ab->lat[li].nphis;
153          SDmultiSamp(rx, 2, randX);
154 <        d = (1. - randX)*sq(cos(M_PI/180.*ab->lat[li].tmin)) +
155 <                randX*sq(cos(M_PI/180.*ab->lat[li+1].tmin));
154 >        d = (1. - rx[0])*sq(cos(M_PI/180.*ab->lat[li].tmin)) +
155 >                rx[0]*sq(cos(M_PI/180.*ab->lat[li+1].tmin));
156          v[2] = d = sqrt(d);     /* cos(pol) */
157          azi = 2.*M_PI*(ndx + rx[1] - .5)/ab->lat[li].nphis;
158          d = sqrt(1. - d*d);     /* sin(pol) */

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines