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

Comparing ray/src/cv/pabopto2bsdf.c (file contents):
Revision 2.29 by greg, Tue Feb 2 00:42:11 2016 UTC vs.
Revision 2.31 by greg, Tue Mar 19 20:27:33 2019 UTC

# Line 128 | Line 128 | init_pabopto_inp(const int i, const char *fname)
128          dv[0] = cos(M_PI/180.*inpfile[i].phi)*dv[2];
129          dv[1] = sin(M_PI/180.*inpfile[i].phi)*dv[2];
130          dv[2] = sqrt(1. - dv[2]*dv[2]);
131 <        pos_from_vec(inpfile[i].igp, dv);
131 >        if (inpfile[i].theta <= FTINY)
132 >                inpfile[i].igp[0] = inpfile[i].igp[1] = grid_res/2 - 1;
133 >        else
134 >                pos_from_vec(inpfile[i].igp, dv);
135          return(1);
136   }
137  
# Line 266 | Line 269 | main(int argc, char *argv[])
269          }
270   #ifdef DEBUG
271          fprintf(stderr, "Minimum BSDF = %.4f\n", bsdf_min);
272 +        fprintf(stderr, "Integrated hemispherical value = %.4f\n", dsf_list->vtotal);
273   #endif
274          min_log = log(bsdf_min*.5 + 1e-5);
275   #if 1                                           /* produce spheres at meas. */

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines