From 5c9b04f975812f0408dde1e4518d71d9edc3550b Mon Sep 17 00:00:00 2001 From: curt Date: Fri, 22 Oct 1999 01:30:39 +0000 Subject: [PATCH] Just a minor tweak. --- src/Main/main.cxx | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/src/Main/main.cxx b/src/Main/main.cxx index 6945772e0..e90c007b9 100644 --- a/src/Main/main.cxx +++ b/src/Main/main.cxx @@ -350,18 +350,21 @@ void fgRenderFrame( void ) { if ( current_options.get_clouds() ) { double diff = fabs( cur_fdm_state->get_Altitude() * FEET_TO_METER - current_options.get_clouds_asl() ); - cout << "altitude diff = " << diff << endl; - if ( diff < 100 ) { - actual_visibility = cur_visibility * diff / 100.0; + // cout << "altitude diff = " << diff << endl; + if ( diff < 125 ) { + actual_visibility = cur_visibility * (diff - 25) / 100.0; + if ( actual_visibility < 0 ) { + actual_visibility = 0; + } } } - cout << "actual visibility = " << actual_visibility << endl; + // cout << "actual visibility = " << actual_visibility << endl; if ( actual_visibility != last_visibility ) { last_visibility = actual_visibility; - cout << "----> updating fog params" << endl; + // cout << "----> updating fog params" << endl; GLfloat fog_exp_density; GLfloat fog_exp2_density; -- 2.39.5