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

Comparing ray/src/common/bsdf_t.c (file contents):
Revision 3.30 by greg, Thu Jul 4 15:14:45 2013 UTC vs.
Revision 3.31 by greg, Thu Aug 8 05:26:56 2013 UTC

# Line 468 | Line 468 | SDqueryTre(const SDTre *sdt, const FVECT outVec, const
468                                          /* convert vector coordinates */
469          if (sdt->st->ndim == 3) {
470                  spinvector(rOutVec, outVec, zvec, -atan2(-inVec[1],-inVec[0]));
471 <                gridPos[0] = .5 - .5*sqrt(inVec[0]*inVec[0] + inVec[1]*inVec[1]);
471 >                gridPos[0] = (.5-FTINY) -
472 >                                .5*sqrt(inVec[0]*inVec[0] + inVec[1]*inVec[1]);
473                  SDdisk2square(gridPos+1, rOutVec[0], rOutVec[1]);
474          } else if (sdt->st->ndim == 4) {
475                  SDdisk2square(gridPos, -inVec[0], -inVec[1]);
# Line 672 | Line 673 | SDgetTreCDist(const FVECT inVec, SDComponent *sdc)
673          if (sdt->st->ndim == 3) {       /* isotropic BSDF? */
674                  if (mode != sdt->sidef) /* XXX unhandled reciprocity */
675                          return &SDemptyCD;
676 <                inCoord[0] = .5 - .5*sqrt(inVec[0]*inVec[0] + inVec[1]*inVec[1]);
676 >                inCoord[0] = (.5-FTINY) -
677 >                                .5*sqrt(inVec[0]*inVec[0] + inVec[1]*inVec[1]);
678          } else if (sdt->st->ndim == 4) {
679                  if (mode != sdt->sidef) /* use reciprocity? */
680                          SDdisk2square(inCoord, inVec[0], inVec[1]);

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines