Remove one dependence on MetaKit.
This commit is contained in:
parent
b23183f018
commit
6665d7d609
8 changed files with 81 additions and 278 deletions
|
@ -266,23 +266,23 @@ double GetAngleDiff_deg( const double &a1, const double &a2) {
|
||||||
// in fg_init.cxx, and are just here temporarily until some rationalisation occurs.
|
// in fg_init.cxx, and are just here temporarily until some rationalisation occurs.
|
||||||
// find basic airport location info from airport database
|
// find basic airport location info from airport database
|
||||||
bool dclFindAirportID( const string& id, FGAirport *a ) {
|
bool dclFindAirportID( const string& id, FGAirport *a ) {
|
||||||
if ( id.length() ) {
|
FGAirport result;
|
||||||
SGPath path( globals->get_fg_root() );
|
|
||||||
path.append( "Airports" );
|
|
||||||
path.append( "simple.mk4" );
|
|
||||||
FGAirports airports( path.c_str() );
|
|
||||||
|
|
||||||
|
if ( id.length() ) {
|
||||||
SG_LOG( SG_GENERAL, SG_INFO, "Searching for airport code = " << id );
|
SG_LOG( SG_GENERAL, SG_INFO, "Searching for airport code = " << id );
|
||||||
|
|
||||||
if ( ! airports.search( id, a ) ) {
|
result = globals->get_airports()->search( id );
|
||||||
|
if ( result.id.empty() ) {
|
||||||
SG_LOG( SG_GENERAL, SG_ALERT,
|
SG_LOG( SG_GENERAL, SG_ALERT,
|
||||||
"Failed to find " << id << " in " << path.str() );
|
"Failed to find " << id << " in simple.apt.gz" );
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
*a = result;
|
||||||
|
|
||||||
SG_LOG( SG_GENERAL, SG_INFO,
|
SG_LOG( SG_GENERAL, SG_INFO,
|
||||||
"Position for " << id << " is ("
|
"Position for " << id << " is ("
|
||||||
<< a->longitude << ", "
|
<< a->longitude << ", "
|
||||||
|
|
|
@ -1,14 +1,11 @@
|
||||||
noinst_LIBRARIES = libAirports.a
|
noinst_LIBRARIES = libAirports.a
|
||||||
|
|
||||||
noinst_PROGRAMS = gensimple genrunways calc_loc
|
noinst_PROGRAMS = genrunways calc_loc
|
||||||
|
|
||||||
libAirports_a_SOURCES = \
|
libAirports_a_SOURCES = \
|
||||||
runways.cxx runways.hxx \
|
runways.cxx runways.hxx \
|
||||||
simple.cxx simple.hxx
|
simple.cxx simple.hxx
|
||||||
|
|
||||||
gensimple_SOURCES = gensimple.cxx
|
|
||||||
gensimple_LDADD = libAirports.a -lsgdebug -lsgmisc -lsgxml -lmk4 -lz
|
|
||||||
|
|
||||||
genrunways_SOURCES = genrunways.cxx
|
genrunways_SOURCES = genrunways.cxx
|
||||||
genrunways_LDADD = libAirports.a -lsgdebug -lsgmisc -lsgxml -lmk4 -lz
|
genrunways_LDADD = libAirports.a -lsgdebug -lsgmisc -lsgxml -lmk4 -lz
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
//
|
//
|
||||||
// simple.cxx -- a really simplistic class to manage airport ID,
|
// simple.cxx -- a really simplistic class to manage airport ID,
|
||||||
// lat, lon of the center of one of it's runways, and
|
// lat, lon of the center of one of it's runways, and
|
||||||
// elevation in feet.
|
// elevation in feet.
|
||||||
//
|
//
|
||||||
// Written by Curtis Olson, started April 1998.
|
// Written by Curtis Olson, started April 1998.
|
||||||
//
|
//
|
||||||
|
@ -35,230 +35,56 @@
|
||||||
#include STL_STRING
|
#include STL_STRING
|
||||||
#include STL_FUNCTIONAL
|
#include STL_FUNCTIONAL
|
||||||
#include STL_ALGORITHM
|
#include STL_ALGORITHM
|
||||||
|
#include STL_IOSTREAM
|
||||||
|
|
||||||
#include "simple.hxx"
|
#include "simple.hxx"
|
||||||
|
|
||||||
SG_USING_NAMESPACE(std);
|
SG_USING_NAMESPACE(std);
|
||||||
|
|
||||||
#ifndef _MSC_VER
|
|
||||||
# define NDEBUG // she don't work without it.
|
|
||||||
#endif
|
|
||||||
#include <mk4.h>
|
|
||||||
#include <mk4str.h>
|
|
||||||
#ifndef _MSC_VER
|
|
||||||
# undef NDEBUG
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef SG_HAVE_STD_INCLUDES
|
|
||||||
# include <istream>
|
|
||||||
#elif defined( __BORLANDC__ ) || defined (__APPLE__)
|
|
||||||
# include <iostream>
|
|
||||||
#else
|
|
||||||
# include <istream.h>
|
|
||||||
#endif
|
|
||||||
SG_USING_STD(istream);
|
SG_USING_STD(istream);
|
||||||
|
|
||||||
|
|
||||||
inline istream&
|
inline istream&
|
||||||
operator >> ( istream& in, FGAirport& a )
|
operator >> ( istream& in, FGAirport& a )
|
||||||
{
|
{
|
||||||
return in >> a.id >> a.latitude >> a.longitude >> a.elevation;
|
string junk;
|
||||||
|
in >> junk >> a.id >> a.latitude >> a.longitude >> a.elevation
|
||||||
|
>> a.code;
|
||||||
|
|
||||||
|
char name[256]; // should never be longer than this, right? :-)
|
||||||
|
in.getline( name, 256 );
|
||||||
|
a.name = name;
|
||||||
|
|
||||||
|
return in;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
FGAirports::FGAirports( const string& file ) {
|
FGAirportList::FGAirportList( const string& file ) {
|
||||||
// open the specified database readonly
|
SG_LOG( SG_GENERAL, SG_DEBUG, "Reading simple airport list: " << file );
|
||||||
storage = new c4_Storage( file.c_str(), false );
|
|
||||||
|
|
||||||
if ( !storage->Strategy().IsValid() ) {
|
|
||||||
SG_LOG( SG_GENERAL, SG_ALERT, "Cannot open file: " << file );
|
|
||||||
exit(-1);
|
|
||||||
}
|
|
||||||
|
|
||||||
vAirport = new c4_View;
|
|
||||||
*vAirport =
|
|
||||||
storage->GetAs("airport[ID:S,Longitude:F,Latitude:F,Elevation:F]");
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// search for the specified id
|
|
||||||
bool
|
|
||||||
FGAirports::search( const string& id, FGAirport* a ) const
|
|
||||||
{
|
|
||||||
c4_StringProp pID ("ID");
|
|
||||||
c4_FloatProp pLon ("Longitude");
|
|
||||||
c4_FloatProp pLat ("Latitude");
|
|
||||||
c4_FloatProp pElev ("Elevation");
|
|
||||||
|
|
||||||
int idx = vAirport->Find(pID[id.c_str()]);
|
|
||||||
SG_LOG( SG_TERRAIN, SG_INFO, "idx = " << idx );
|
|
||||||
|
|
||||||
if ( idx == -1 ) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
c4_RowRef r = vAirport->GetAt(idx);
|
|
||||||
a->id = (const char *) pID(r); /// NHV fix wrong case crash
|
|
||||||
a->longitude = (double) pLon(r);
|
|
||||||
a->latitude = (double) pLat(r);
|
|
||||||
a->elevation = (double) pElev(r);
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
FGAirport
|
|
||||||
FGAirports::search( const string& id ) const
|
|
||||||
{
|
|
||||||
FGAirport a;
|
|
||||||
search( id, &a );
|
|
||||||
return a;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// Destructor
|
|
||||||
FGAirports::~FGAirports( void ) {
|
|
||||||
delete storage;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// Constructor
|
|
||||||
FGAirportsUtil::FGAirportsUtil() {
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// load the data
|
|
||||||
int FGAirportsUtil::load( const string& file ) {
|
|
||||||
FGAirport a;
|
|
||||||
|
|
||||||
airports.erase( airports.begin(), airports.end() );
|
|
||||||
|
|
||||||
|
// open the specified file for reading
|
||||||
sg_gzifstream in( file );
|
sg_gzifstream in( file );
|
||||||
if ( !in.is_open() ) {
|
if ( !in.is_open() ) {
|
||||||
SG_LOG( SG_GENERAL, SG_ALERT, "Cannot open file: " << file );
|
SG_LOG( SG_GENERAL, SG_ALERT, "Cannot open file: " << file );
|
||||||
exit(-1);
|
exit(-1);
|
||||||
} else {
|
|
||||||
SG_LOG( SG_GENERAL, SG_ALERT, "opened: " << file );
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// skip first line of file
|
// skip header line
|
||||||
char tmp[2048];
|
in >> skipeol;
|
||||||
in.getline( tmp, 2048 );
|
|
||||||
|
|
||||||
// read in each line of the file
|
while ( in ) {
|
||||||
|
FGAirport a;
|
||||||
#ifdef __MWERKS__
|
in >> a;
|
||||||
|
airports[a.id] = a;
|
||||||
in >> ::skipws;
|
|
||||||
char c = 0;
|
|
||||||
while ( in.get(c) && c != '\0' ) {
|
|
||||||
if ( c == 'A' ) {
|
|
||||||
in >> a;
|
|
||||||
SG_LOG( SG_GENERAL, SG_INFO, a.id );
|
|
||||||
in >> skipeol;
|
|
||||||
airports.insert(a);
|
|
||||||
} else if ( c == 'R' ) {
|
|
||||||
in >> skipeol;
|
|
||||||
} else {
|
|
||||||
in >> skipeol;
|
|
||||||
}
|
|
||||||
in >> ::skipws;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#else
|
|
||||||
|
|
||||||
in >> ::skipws;
|
|
||||||
string token;
|
|
||||||
while ( ! in.eof() ) {
|
|
||||||
in >> token;
|
|
||||||
if ( token == "A" ) {
|
|
||||||
in >> a;
|
|
||||||
SG_LOG( SG_GENERAL, SG_INFO, "in <- " << a.id );
|
|
||||||
in >> skipeol;
|
|
||||||
airports.insert(a);
|
|
||||||
} else if ( token == "R" ) {
|
|
||||||
in >> skipeol;
|
|
||||||
} else {
|
|
||||||
in >> skipeol;
|
|
||||||
}
|
|
||||||
in >> ::skipws;
|
|
||||||
}
|
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
||||||
return 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// save the data in gdbm format
|
|
||||||
bool FGAirportsUtil::dump_mk4( const string& file ) {
|
|
||||||
|
|
||||||
// open database for writing
|
|
||||||
c4_Storage storage( file.c_str(), true );
|
|
||||||
|
|
||||||
// need to do something about error handling here!
|
|
||||||
|
|
||||||
// define the properties
|
|
||||||
c4_StringProp pID ("ID");
|
|
||||||
c4_FloatProp pLon ("Longitude");
|
|
||||||
c4_FloatProp pLat ("Latitude");
|
|
||||||
c4_FloatProp pElev ("Elevation");
|
|
||||||
|
|
||||||
// Start with an empty view of the proper structure.
|
|
||||||
c4_View vAirport =
|
|
||||||
storage.GetAs("airport[ID:S,Longitude:F,Latitude:F,Elevation:F]");
|
|
||||||
|
|
||||||
c4_Row row;
|
|
||||||
|
|
||||||
const_iterator current = airports.begin();
|
|
||||||
const_iterator end = airports.end();
|
|
||||||
while ( current != end ) {
|
|
||||||
// add each airport record
|
|
||||||
SG_LOG( SG_TERRAIN, SG_BULK, "out -> " << current->id );
|
|
||||||
pID (row) = current->id.c_str();
|
|
||||||
pLon (row) = current->longitude;
|
|
||||||
pLat (row) = current->latitude;
|
|
||||||
pElev (row) = current->elevation;
|
|
||||||
vAirport.Add(row);
|
|
||||||
|
|
||||||
++current;
|
|
||||||
}
|
|
||||||
|
|
||||||
// commit our changes
|
|
||||||
storage.Commit();
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// search for the specified id
|
// search for the specified id
|
||||||
bool
|
FGAirport FGAirportList::search( const string& id) {
|
||||||
FGAirportsUtil::search( const string& id, FGAirport* a ) const
|
return airports[id];
|
||||||
{
|
|
||||||
const_iterator it = airports.find( FGAirport(id) );
|
|
||||||
if ( it != airports.end() )
|
|
||||||
{
|
|
||||||
*a = *it;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
FGAirport
|
|
||||||
FGAirportsUtil::search( const string& id ) const
|
|
||||||
{
|
|
||||||
FGAirport a;
|
|
||||||
this->search( id, &a );
|
|
||||||
return a;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// Destructor
|
// Destructor
|
||||||
FGAirportsUtil::~FGAirportsUtil( void ) {
|
FGAirportList::~FGAirportList( void ) {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -23,8 +23,8 @@
|
||||||
// $Id$
|
// $Id$
|
||||||
|
|
||||||
|
|
||||||
#ifndef _SIMPLE_HXX
|
#ifndef _FG_SIMPLE_HXX
|
||||||
#define _SIMPLE_HXX
|
#define _FG_SIMPLE_HXX
|
||||||
|
|
||||||
|
|
||||||
#ifndef __cplusplus
|
#ifndef __cplusplus
|
||||||
|
@ -39,17 +39,23 @@
|
||||||
#include <simgear/compiler.h>
|
#include <simgear/compiler.h>
|
||||||
|
|
||||||
#include STL_STRING
|
#include STL_STRING
|
||||||
#include <set>
|
#include <map>
|
||||||
|
|
||||||
// Forward declarations.
|
|
||||||
class c4_Storage;
|
|
||||||
class c4_View;
|
|
||||||
|
|
||||||
SG_USING_STD(string);
|
SG_USING_STD(string);
|
||||||
SG_USING_STD(set);
|
SG_USING_STD(map);
|
||||||
|
|
||||||
|
|
||||||
class FGAirport {
|
class FGAirport {
|
||||||
|
|
||||||
|
public:
|
||||||
|
|
||||||
|
string id;
|
||||||
|
double longitude;
|
||||||
|
double latitude;
|
||||||
|
double elevation;
|
||||||
|
string code;
|
||||||
|
string name;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
||||||
FGAirport( const string& name = "",
|
FGAirport( const string& name = "",
|
||||||
|
@ -62,76 +68,35 @@ public:
|
||||||
return id < a.id;
|
return id < a.id;
|
||||||
}
|
}
|
||||||
|
|
||||||
public:
|
|
||||||
|
|
||||||
string id;
|
|
||||||
double longitude;
|
|
||||||
double latitude;
|
|
||||||
double elevation;
|
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
typedef map < string, FGAirport > airport_map;
|
||||||
|
typedef airport_map::iterator airport_map_iterator;
|
||||||
|
typedef airport_map::const_iterator const_airport_map_iterator;
|
||||||
|
|
||||||
class FGAirports {
|
|
||||||
|
class FGAirportList {
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
||||||
c4_Storage *storage;
|
airport_map airports;
|
||||||
c4_View *vAirport;
|
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
||||||
// Constructor
|
// Constructor
|
||||||
FGAirports( const string& file );
|
FGAirportList( const string& file );
|
||||||
|
|
||||||
// Destructor
|
// Destructor
|
||||||
~FGAirports();
|
~FGAirportList();
|
||||||
|
|
||||||
// search for the specified id.
|
// search for the specified id.
|
||||||
// Returns true if successful, otherwise returns false.
|
// Returns true if successful, otherwise returns false.
|
||||||
// On success, airport data is returned thru "airport" pointer.
|
// On success, airport data is returned thru "airport" pointer.
|
||||||
// "airport" is not changed if "apt" is not found.
|
// "airport" is not changed if "apt" is not found.
|
||||||
bool search( const string& id, FGAirport* airport ) const;
|
FGAirport search( const string& id );
|
||||||
FGAirport search( const string& id ) const;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
class FGAirportsUtil {
|
#endif // _FG_SIMPLE_HXX
|
||||||
public:
|
|
||||||
#ifdef SG_NO_DEFAULT_TEMPLATE_ARGS
|
|
||||||
typedef set< FGAirport, less< FGAirport > > container;
|
|
||||||
#else
|
|
||||||
typedef set< FGAirport > container;
|
|
||||||
#endif
|
|
||||||
typedef container::iterator iterator;
|
|
||||||
typedef container::const_iterator const_iterator;
|
|
||||||
|
|
||||||
private:
|
|
||||||
container airports;
|
|
||||||
|
|
||||||
public:
|
|
||||||
|
|
||||||
// Constructor
|
|
||||||
FGAirportsUtil();
|
|
||||||
|
|
||||||
// Destructor
|
|
||||||
~FGAirportsUtil();
|
|
||||||
|
|
||||||
// load the data
|
|
||||||
int load( const string& file );
|
|
||||||
|
|
||||||
// save the data in metakit format
|
|
||||||
bool dump_mk4( const string& file );
|
|
||||||
|
|
||||||
// search for the specified id.
|
|
||||||
// Returns true if successful, otherwise returns false.
|
|
||||||
// On success, airport data is returned thru "airport" pointer.
|
|
||||||
// "airport" is not changed if "id" is not found.
|
|
||||||
bool search( const string& id, FGAirport* airport ) const;
|
|
||||||
FGAirport search( const string& id ) const;
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
#endif // _SIMPLE_HXX
|
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -99,7 +99,7 @@ fgfs_LDADD = \
|
||||||
$(top_builddir)/src/Systems/libSystems.a \
|
$(top_builddir)/src/Systems/libSystems.a \
|
||||||
$(top_builddir)/src/Time/libTime.a \
|
$(top_builddir)/src/Time/libTime.a \
|
||||||
$(WEATHER_LIBS) \
|
$(WEATHER_LIBS) \
|
||||||
-lsgroute -lsgsky -lsgsound -lsgephem -lsgmaterial -lsgtgdb -lsgmodel \
|
-lsgroute -lsgclouds3d -lsgsky -lsgsound -lsgephem -lsgmaterial -lsgtgdb -lsgmodel \
|
||||||
-lsgtiming -lsgio -lsgscreen -lsgmath -lsgbucket -lsgprops -lsgdebug \
|
-lsgtiming -lsgio -lsgscreen -lsgmath -lsgbucket -lsgprops -lsgdebug \
|
||||||
-lsgmagvar -lsgmisc -lsgxml -lsgsound -lsgserial $(CLOUD3D_LIBS) \
|
-lsgmagvar -lsgmisc -lsgxml -lsgsound -lsgserial $(CLOUD3D_LIBS) \
|
||||||
$(THREAD_LIBS) \
|
$(THREAD_LIBS) \
|
||||||
|
|
|
@ -556,23 +556,23 @@ bool fgInitConfig ( int argc, char **argv ) {
|
||||||
|
|
||||||
// find basic airport location info from airport database
|
// find basic airport location info from airport database
|
||||||
bool fgFindAirportID( const string& id, FGAirport *a ) {
|
bool fgFindAirportID( const string& id, FGAirport *a ) {
|
||||||
|
FGAirport result;
|
||||||
if ( id.length() ) {
|
if ( id.length() ) {
|
||||||
SGPath path( globals->get_fg_root() );
|
|
||||||
path.append( "Airports" );
|
|
||||||
path.append( "simple.mk4" );
|
|
||||||
FGAirports airports( path.c_str() );
|
|
||||||
|
|
||||||
SG_LOG( SG_GENERAL, SG_INFO, "Searching for airport code = " << id );
|
SG_LOG( SG_GENERAL, SG_INFO, "Searching for airport code = " << id );
|
||||||
|
|
||||||
if ( ! airports.search( id, a ) ) {
|
result = globals->get_airports()->search( id );
|
||||||
|
|
||||||
|
if ( result.id.empty() ) {
|
||||||
SG_LOG( SG_GENERAL, SG_ALERT,
|
SG_LOG( SG_GENERAL, SG_ALERT,
|
||||||
"Failed to find " << id << " in " << path.str() );
|
"Failed to find " << id << " in simple.apt.gz" );
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
*a = result;
|
||||||
|
|
||||||
SG_LOG( SG_GENERAL, SG_INFO,
|
SG_LOG( SG_GENERAL, SG_INFO,
|
||||||
"Position for " << id << " is ("
|
"Position for " << id << " is ("
|
||||||
<< a->longitude << ", "
|
<< a->longitude << ", "
|
||||||
|
@ -943,11 +943,18 @@ static bool fgSetPosFromFix( const string& id ) {
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Initialize vor/ndb/ils/fix list management and query systems
|
* Initialize vor/ndb/ils/fix list management and query systems (as
|
||||||
|
* well as simple airport db list)
|
||||||
*/
|
*/
|
||||||
bool
|
bool
|
||||||
fgInitNav ()
|
fgInitNav ()
|
||||||
{
|
{
|
||||||
|
SG_LOG(SG_GENERAL, SG_INFO, "Loading Simple Airport List");
|
||||||
|
SGPath p_simple( globals->get_fg_root() );
|
||||||
|
p_simple.append( "Airports/simple.apt" );
|
||||||
|
FGAirportList *airports = new FGAirportList( p_simple.str() );
|
||||||
|
globals->set_airports( airports );
|
||||||
|
|
||||||
SG_LOG(SG_GENERAL, SG_INFO, "Loading Navaids");
|
SG_LOG(SG_GENERAL, SG_INFO, "Loading Navaids");
|
||||||
|
|
||||||
SG_LOG(SG_GENERAL, SG_INFO, " VOR/NDB");
|
SG_LOG(SG_GENERAL, SG_INFO, " VOR/NDB");
|
||||||
|
|
|
@ -57,6 +57,7 @@ FGGlobals::FGGlobals() :
|
||||||
route( NULL ),
|
route( NULL ),
|
||||||
current_panel( NULL ),
|
current_panel( NULL ),
|
||||||
soundmgr( NULL ),
|
soundmgr( NULL ),
|
||||||
|
airports( NULL ),
|
||||||
ATC_mgr( NULL ),
|
ATC_mgr( NULL ),
|
||||||
ATC_display( NULL ),
|
ATC_display( NULL ),
|
||||||
AI_mgr( NULL ),
|
AI_mgr( NULL ),
|
||||||
|
|
|
@ -59,6 +59,7 @@ class SGRoute;
|
||||||
class SGTime;
|
class SGTime;
|
||||||
class SGSoundMgr;
|
class SGSoundMgr;
|
||||||
|
|
||||||
|
class FGAirportList;
|
||||||
class FGAIMgr;
|
class FGAIMgr;
|
||||||
class FGATCMgr;
|
class FGATCMgr;
|
||||||
class FGATCDisplay;
|
class FGATCDisplay;
|
||||||
|
@ -134,6 +135,9 @@ private:
|
||||||
// sound manager
|
// sound manager
|
||||||
SGSoundMgr *soundmgr;
|
SGSoundMgr *soundmgr;
|
||||||
|
|
||||||
|
// Simple Airport List
|
||||||
|
FGAirportList *airports;
|
||||||
|
|
||||||
// ATC manager
|
// ATC manager
|
||||||
FGATCMgr *ATC_mgr;
|
FGATCMgr *ATC_mgr;
|
||||||
|
|
||||||
|
@ -240,6 +244,9 @@ public:
|
||||||
inline SGRoute *get_route() const { return route; }
|
inline SGRoute *get_route() const { return route; }
|
||||||
inline void set_route( SGRoute *r ) { route = r; }
|
inline void set_route( SGRoute *r ) { route = r; }
|
||||||
|
|
||||||
|
inline FGAirportList *get_airports() const { return airports; }
|
||||||
|
inline void set_airports( FGAirportList *a ) {airports = a; }
|
||||||
|
|
||||||
inline FGATCMgr *get_ATC_mgr() const { return ATC_mgr; }
|
inline FGATCMgr *get_ATC_mgr() const { return ATC_mgr; }
|
||||||
inline void set_ATC_mgr( FGATCMgr *a ) {ATC_mgr = a; }
|
inline void set_ATC_mgr( FGATCMgr *a ) {ATC_mgr = a; }
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue