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

Comparing ray/src/gen/gendaymtx.c (file contents):
Revision 2.25 by greg, Sat Aug 20 15:42:38 2016 UTC vs.
Revision 2.26 by greg, Fri Apr 28 16:07:34 2017 UTC

# Line 953 | Line 953 | int CalcSkyParamFromIllum()
953                  /* Convert illuminance to irradiance */
954                  index = GetCategoryIndex();
955                  diff_irrad = diff_illum / CalcDiffuseIllumRatio(index);
956 <                dir_irrad = dir_illum / CalcDirectIllumRatio(index);
956 >                dir_irrad = CalcDirectIllumRatio(index);
957 >                if (dir_irrad > 0.1)
958 >                        dir_irrad = dir_illum / dir_irrad;
959          
960                  /* Calculate sky brightness and clearness */
961                  sky_brightness = CalcSkyBrightness();

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines