From 5c8e6a5841caa393de2287eace738a5f6c16ba8c Mon Sep 17 00:00:00 2001 From: curt <curt> Date: Thu, 12 Dec 2002 01:24:48 +0000 Subject: [PATCH] Tweak taxi light rendering so they don't look completely bogus at dusk. --- src/Main/fg_init.cxx | 8 +++++--- src/Main/main.cxx | 7 +++++-- 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/src/Main/fg_init.cxx b/src/Main/fg_init.cxx index 8febea3b8..ca47053c1 100644 --- a/src/Main/fg_init.cxx +++ b/src/Main/fg_init.cxx @@ -935,14 +935,16 @@ static void fgSetDistOrAltFromGlideSlope() { alt = fabs(od*tan(gs)) + apt_elev; fgSetDouble("/sim/presets/altitude-ft", alt); fgSetBool("/sim/presets/onground", false); - SG_LOG(SG_GENERAL,SG_INFO, "Calculated altitude as: " << alt << " ft"); + SG_LOG( SG_GENERAL, SG_INFO, "Calculated altitude as: " + << alt << " ft" ); } else if( fabs(gs) > 0.01 && alt > 0 && fabs(od) < 0.1) { // set offset-distance from glideslope and altitude od = (alt - apt_elev) / tan(gs); od *= -1*SG_FEET_TO_METER * SG_METER_TO_NM; fgSetDouble("/sim/presets/offset-distance", od); - SG_LOG(SG_GENERAL, SG_INFO, "Calculated offset distance as: " - << od << " nm"); + fgSetBool("/sim/presets/onground", false); + SG_LOG( SG_GENERAL, SG_INFO, "Calculated offset distance as: " + << od << " nm" ); } else if( fabs(gs) > 0.01 ) { SG_LOG( SG_GENERAL, SG_ALERT, "Glideslope given but not altitude or offset-distance." ); diff --git a/src/Main/main.cxx b/src/Main/main.cxx index 598145009..12cad471d 100644 --- a/src/Main/main.cxx +++ b/src/Main/main.cxx @@ -767,7 +767,10 @@ void fgRenderFrame() { ssgCullAndDraw( globals->get_scenery()->get_rwy_lights_root() ); // change punch through and then draw taxi lighting - glFogf (GL_FOG_DENSITY, taxi_exp2_punch_through); + glFogf ( GL_FOG_DENSITY, fog_exp2_density ); + // sgVec3 taxi_fog; + // sgSetVec3( taxi_fog, 0.0, 0.0, 0.0 ); + // glFogfv ( GL_FOG_COLOR, taxi_fog ); ssgCullAndDraw( globals->get_scenery()->get_taxi_lights_root() ); // clean up lighting @@ -1548,7 +1551,7 @@ static bool fgMainInit( int argc, char **argv ) { cerr << endl << "Base package check failed ... " \ << "Found version " << base_version << " at: " \ << globals->get_fg_root() << endl; - cerr << "Please upgrade to version" << required_version << endl; + cerr << "Please upgrade to version: " << required_version << endl; exit(-1); }