| # | Line 133 | Line 133 | computesky() /* compute sky parameters */ | |
|---|---|---|
| 133 | zenithbr = (1.376*turbidity-1.81)*tan(altitude)+0.38; | |
| 134 | zenithbr *= 1000.0/683.0; | |
| 135 | } | |
| 136 | + | if (zenithbr < 0.0) |
| 137 | + | zenithbr = 0.0; |
| 138 | /* Compute horizontal radiance */ | |
| 139 | if (cloudy) { | |
| 140 | groundbr = zenithbr*0.777778; | |
| – | Removed lines |
| + | Added lines |
| < | Changed lines (old) |
| > | Changed lines (new) |