From: Erik Hofman Date: Wed, 25 May 2016 08:30:34 +0000 (+0200) Subject: Prevent rf2 from becoming inf X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=b2772edbce2b9f420fbd4c9a57e3a9f3af978a97;p=flightgear.git Prevent rf2 from becoming inf --- diff --git a/src/Time/light.cxx b/src/Time/light.cxx index 8600372ce..e31e4ad1d 100644 --- a/src/Time/light.cxx +++ b/src/Time/light.cxx @@ -358,8 +358,8 @@ void FGLight::update_adj_fog_color () { float avf = 0.87 - (45000 - av) / 83333.33; float sif = 0.5 - cos(_sun_angle*2)/2; - if (sif < 1e-4) - sif = 1e-4; + if (sif < 1e-3) + sif = 1e-3; // determine horizontal angle between current view direction and sun // since _sun_rotation is relative to South, and heading is in the local frame