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

Comparing ray/src/common/dircode.c (file contents):
Revision 2.11 by greg, Wed Mar 4 02:55:43 2020 UTC vs.
Revision 2.12 by greg, Fri Mar 6 19:05:19 2020 UTC

# Line 61 | Line 61 | decodedir(FVECT dv, int32 dc)  /* decode a normalized d
61                  dv[0] = dv[1] = dv[2] = 0.;
62                  return;
63          }
64 <        d1 = ((dc>>F1SFT & FMASK)+.5)*(1./DCSCALE);
65 <        d2 = ((dc>>F2SFT & FMASK)+.5)*(1./DCSCALE);
64 >        d1 = (dc>>F1SFT & FMASK)*(1./DCSCALE);
65 >        d2 = (dc>>F2SFT & FMASK)*(1./DCSCALE);
66          der = sqrt(1. - d1*d1 - d2*d2);
67          if (dc & F1X) {
68                  dv[0] = d1;

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines