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

Comparing ray/src/gen/genssky.c (file contents):
Revision 2.6 by greg, Wed Oct 9 17:22:42 2024 UTC vs.
Revision 2.7 by greg, Thu Apr 10 23:30:58 2025 UTC

# Line 260 | Line 260 | int gen_spect_sky(DATARRAY *tau_clear, DATARRAY *scat_
260      }
261      free(indirect_irradiance_clear);
262      diffuse_irradiance = wmean2(diffuse_irradiance, overcast_ghi, cloud_cover);
263 <    dif_ratio = difhor / WHTEFFICACY / diffuse_irradiance / 1.15;       /* fudge */
263 >    if (diffuse_irradiance > 0) {
264 >        dif_ratio = difhor / WHTEFFICACY / diffuse_irradiance / 1.15;       /* fudge */
265 >    }
266    }
267    int i, j, k;
268    for (j = 0; j < yres; ++j) {

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines