From: curt Date: Fri, 30 Jun 2000 21:46:41 +0000 (+0000) Subject: Various odds and ends tweaks. X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=db6da3a89648a71b2bfe6f84b61b0266b65e6cc5;p=flightgear.git Various odds and ends tweaks. --- diff --git a/src/Main/fg_init.cxx b/src/Main/fg_init.cxx index e73b39fbb..652166bf6 100644 --- a/src/Main/fg_init.cxx +++ b/src/Main/fg_init.cxx @@ -293,7 +293,8 @@ bool fgInitSubsystems( void ) { if( global_tile_mgr.init() ) { // Load the local scenery data - global_tile_mgr.update(); + global_tile_mgr.update( cur_fdm_state->get_Longitude(), + cur_fdm_state->get_Latitude() ); } else { FG_LOG( FG_GENERAL, FG_ALERT, "Error in Tile Manager initialization!" ); exit(-1); @@ -599,7 +600,8 @@ void fgReInitSubsystems( void ) fgInitPosition(); if( global_tile_mgr.init() ) { // Load the local scenery data - global_tile_mgr.update(); + global_tile_mgr.update( cur_fdm_state->get_Longitude(), + cur_fdm_state->get_Latitude() ); } else { FG_LOG( FG_GENERAL, FG_ALERT, "Error in Tile Manager initialization!" ); exit(-1); diff --git a/src/Main/keyboard.cxx b/src/Main/keyboard.cxx index eff00308b..6e5e78a98 100644 --- a/src/Main/keyboard.cxx +++ b/src/Main/keyboard.cxx @@ -486,7 +486,8 @@ void GLUTspecialkey(int k, int x, int y) { BusyCursor(0); if( global_tile_mgr.init() ) { // Load the local scenery data - global_tile_mgr.update(); + global_tile_mgr.update( cur_fdm_state->get_Longitude(), + cur_fdm_state->get_Latitude() ); } else { FG_LOG( FG_GENERAL, FG_ALERT, "Error in Tile Manager initialization!" ); diff --git a/src/Main/main.cxx b/src/Main/main.cxx index e37ba9542..6a9a2971a 100644 --- a/src/Main/main.cxx +++ b/src/Main/main.cxx @@ -368,8 +368,7 @@ void fgRenderFrame( void ) { thesky->set_visibility( current_weather.get_visibility() ); #endif - thesky->modify_vis( cur_fdm_state->get_Altitude() - * FEET_TO_METER, + thesky->modify_vis( cur_fdm_state->get_Altitude() * FEET_TO_METER, ( global_multi_loop * current_options.get_speed_up() ) / @@ -873,7 +872,8 @@ static void fgMainLoop( void ) { #endif // see if we need to load any new scenery tiles - global_tile_mgr.update(); + global_tile_mgr.update( cur_fdm_state->get_Longitude(), + cur_fdm_state->get_Latitude() ); // Process/manage pending events global_events.Process(); @@ -1355,9 +1355,8 @@ int main( int argc, char **argv ) { ephem->getPlanets(), 60000.0, ephem->getNumStars(), ephem->getStars(), 60000.0 ); - thesky->add_cloud_layer( 1000.0, 200.0, 50.0, SG_CLOUD_MOSTLY_SUNNY ); - thesky->add_cloud_layer( 1800.0, 400.0, 100.0, SG_CLOUD_OVERCAST ); - thesky->add_cloud_layer( 5000.0, 20.0, 10.0, SG_CLOUD_CIRRUS ); + thesky->add_cloud_layer( 2600.0, 200.0, 50.0, SG_CLOUD_MOSTLY_SUNNY ); + thesky->add_cloud_layer( 6000.0, 20.0, 10.0, SG_CLOUD_CIRRUS ); // Terrain branch terrain = new ssgBranch; diff --git a/src/Scenery/tilemgr.cxx b/src/Scenery/tilemgr.cxx index a90c4a0a6..2f71d6bff 100644 --- a/src/Scenery/tilemgr.cxx +++ b/src/Scenery/tilemgr.cxx @@ -366,7 +366,7 @@ void FGTileMgr::initialize_queue( void ) // given the current lon/lat, fill in the array of local chunks. If // the chunk isn't already in the cache, then read it from disk. -int FGTileMgr::update( void ) { +int FGTileMgr::update( double junk1, double junk2 ) { // FG_LOG( FG_TERRAIN, FG_DEBUG, "FGTileMgr::update()" ); FGInterface *f = current_aircraft.fdm_state; diff --git a/src/Scenery/tilemgr.hxx b/src/Scenery/tilemgr.hxx index 37894b79d..0d616bdb4 100644 --- a/src/Scenery/tilemgr.hxx +++ b/src/Scenery/tilemgr.hxx @@ -146,7 +146,7 @@ public: // given the current lon/lat, fill in the array of local chunks. // If the chunk isn't already in the cache, then read it from // disk. - int update( void ); + int update( double junk1, double junk2 ); // Determine scenery altitude. Normally this just happens when we // render the scene, but we'd also like to be able to do this