]> git.mxchange.org Git - flightgear.git/commitdiff
Various odds and ends tweaks.
authorcurt <curt>
Fri, 30 Jun 2000 21:46:41 +0000 (21:46 +0000)
committercurt <curt>
Fri, 30 Jun 2000 21:46:41 +0000 (21:46 +0000)
src/Main/fg_init.cxx
src/Main/keyboard.cxx
src/Main/main.cxx
src/Scenery/tilemgr.cxx
src/Scenery/tilemgr.hxx

index e73b39fbb35048e53da81c89b6fc45bb90fe2a77..652166bf6f92496de38c20b74fb730e7b5ab47c2 100644 (file)
@@ -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);
index eff00308b5b88de947106407bf40d05ae2820e7c..6e5e78a98c91ba0b08056c638a457a2d3790eb33 100644 (file)
@@ -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!" );
index e37ba954207384c31c9992f0f263f26385a420e6..6a9a2971a2c5d48555d9ac456e66528a2a90bbe0 100644 (file)
@@ -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;
index a90c4a0a6c95d2e7f52c958eaab8c3f35559fc53..2f71d6bff73ae270499d85c233f7c0b1356bea68 100644 (file)
@@ -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;
index 37894b79d27ac4b04ddb31326a324c53d77151bd..0d616bdb4da913cff33cdce578b597a0e1ddb020 100644 (file)
@@ -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