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

Comparing ray/src/cv/bsdfinterp.c (file contents):
Revision 2.17 by greg, Wed Feb 19 05:16:06 2014 UTC vs.
Revision 2.18 by greg, Mon Mar 24 17:22:33 2014 UTC

# Line 215 | Line 215 | get_interp(MIGRATION *miga[3], FVECT invec)
215                      for (miga[0] = rbf->ejl; miga[0] != NULL;
216                                          miga[0] = nextedge(rbf,miga[0]))
217                          if (opp_rbf(rbf,miga[0]) == rbf->next) {
218 <                                double  nf = 1. - rbf->invec[2]*rbf->invec[2];
218 >                                double  nf = 1. -
219 >                                        rbf->next->invec[2]*rbf->next->invec[2];
220                                  if (nf > FTINY) {       /* rotate to match */
221                                          nf = sqrt((1.-invec[2]*invec[2])/nf);
222 <                                        invec[0] = nf*rbf->invec[0];
223 <                                        invec[1] = nf*rbf->invec[1];
222 >                                        invec[0] = nf*rbf->next->invec[0];
223 >                                        invec[1] = nf*rbf->next->invec[1];
224                                  }
225 <                                return(0);
225 >                                return(0);      /* rotational symmetry */
226                          }
227                      break;
228                  }

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines