Remove references to old (unused) airways code
This commit is contained in:
parent
fe16732783
commit
f5c2c630eb
12 changed files with 47 additions and 70 deletions
|
@ -29,6 +29,7 @@
|
|||
#include <Scenery/scenery.hxx>
|
||||
#include <Scenery/tilemgr.hxx>
|
||||
#include <Airports/dynamics.hxx>
|
||||
#include <Airports/simple.hxx>
|
||||
|
||||
#include <string>
|
||||
#include <math.h>
|
||||
|
|
|
@ -24,26 +24,18 @@
|
|||
#include <string>
|
||||
|
||||
|
||||
#include <Airports/simple.hxx>
|
||||
#include <Navaids/awynet.hxx>
|
||||
|
||||
#include "AIBase.hxx"
|
||||
|
||||
|
||||
|
||||
using std::vector;
|
||||
using std::string;
|
||||
|
||||
class FGTaxiRoute;
|
||||
class FGRunway;
|
||||
class FGAIAircraft;
|
||||
class FGAirport;
|
||||
class SGGeod;
|
||||
|
||||
class FGAIFlightPlan {
|
||||
|
||||
public:
|
||||
|
||||
typedef struct {
|
||||
string name;
|
||||
std::string name;
|
||||
double latitude;
|
||||
double longitude;
|
||||
double altitude;
|
||||
|
@ -56,11 +48,11 @@ public:
|
|||
int routeIndex; // For AI/ATC purposes;
|
||||
double time_sec;
|
||||
double trackLength; // distance from previous waypoint (for AI purposes);
|
||||
string time;
|
||||
std::string time;
|
||||
|
||||
} waypoint;
|
||||
FGAIFlightPlan();
|
||||
FGAIFlightPlan(const string& filename);
|
||||
FGAIFlightPlan(const std::string& filename);
|
||||
FGAIFlightPlan(FGAIAircraft *,
|
||||
const std::string& p,
|
||||
double course,
|
||||
|
@ -73,9 +65,9 @@ public:
|
|||
double lat,
|
||||
double lon,
|
||||
double speed,
|
||||
const string& fltType,
|
||||
const string& acType,
|
||||
const string& airline);
|
||||
const std::string& fltType,
|
||||
const std::string& acType,
|
||||
const std::string& airline);
|
||||
~FGAIFlightPlan();
|
||||
|
||||
waypoint* const getPreviousWaypoint( void ) const;
|
||||
|
@ -91,18 +83,18 @@ public:
|
|||
double getLeadDistance( void ) const {return lead_distance;}
|
||||
double getBearing(waypoint* previous, waypoint* next) const;
|
||||
double getBearing(double lat, double lon, waypoint* next) const;
|
||||
double checkTrackLength(string wptName);
|
||||
double checkTrackLength(std::string wptName);
|
||||
time_t getStartTime() const { return start_time; }
|
||||
time_t getArrivalTime() const { return arrivalTime; }
|
||||
|
||||
void create(FGAIAircraft *, FGAirport *dep, FGAirport *arr, int leg, double alt, double speed, double lat, double lon,
|
||||
bool firstLeg, double radius, const string& fltType, const string& aircraftType, const string& airline, double distance);
|
||||
bool firstLeg, double radius, const std::string& fltType, const std::string& aircraftType, const std::string& airline, double distance);
|
||||
|
||||
void setLeg(int val) { leg = val;}
|
||||
void setTime(time_t st) { start_time = st; }
|
||||
int getGate() const { return gateId; }
|
||||
double getLeadInAngle() const { return leadInAngle; }
|
||||
const string& getRunway() const;
|
||||
const std::string& getRunway() const;
|
||||
|
||||
void setRepeat(bool r) { repeat = r; }
|
||||
bool getRepeat(void) const { return repeat; }
|
||||
|
@ -111,16 +103,16 @@ public:
|
|||
int getRouteIndex(int i); // returns the AI related index of this current routes.
|
||||
FGTaxiRoute *getTaxiRoute() { return taxiRoute; }
|
||||
void deleteTaxiRoute();
|
||||
string getRunway() { return activeRunway; }
|
||||
std::string getRunway() { return activeRunway; }
|
||||
bool isActive(time_t time) {return time >= this->getStartTime();}
|
||||
|
||||
void setRunway(string rwy) { activeRunway = rwy; };
|
||||
string getRunwayClassFromTrafficType(string fltType);
|
||||
void setRunway(std::string rwy) { activeRunway = rwy; };
|
||||
std::string getRunwayClassFromTrafficType(std::string fltType);
|
||||
|
||||
void addWaypoint(waypoint* wpt) { waypoints.push_back(wpt); };
|
||||
|
||||
void setName(string n) { name = n; };
|
||||
string getName() { return name; };
|
||||
void setName(std::string n) { name = n; };
|
||||
std::string getName() { return name; };
|
||||
|
||||
void setSID(FGAIFlightPlan* fp) { sid = fp;};
|
||||
FGAIFlightPlan* getSID() { return sid; };
|
||||
|
@ -128,7 +120,7 @@ public:
|
|||
private:
|
||||
FGRunway* rwy;
|
||||
FGAIFlightPlan *sid;
|
||||
typedef vector <waypoint*> wpt_vector_type;
|
||||
typedef std::vector <waypoint*> wpt_vector_type;
|
||||
typedef wpt_vector_type::const_iterator wpt_vector_iterator;
|
||||
|
||||
|
||||
|
@ -143,26 +135,25 @@ private:
|
|||
time_t arrivalTime; // For AI/ATC purposes.
|
||||
int leg;
|
||||
int gateId, lastNodeVisited;
|
||||
string activeRunway;
|
||||
FGAirRoute airRoute;
|
||||
std::string activeRunway;
|
||||
FGTaxiRoute *taxiRoute;
|
||||
string name;
|
||||
std::string name;
|
||||
|
||||
void createPushBack(FGAIAircraft *, bool, FGAirport*, double, double, double, const string&, const string&, const string&);
|
||||
void createPushBackFallBack(FGAIAircraft *, bool, FGAirport*, double, double, double, const string&, const string&, const string&);
|
||||
void createTakeOff(FGAIAircraft *, bool, FGAirport *, double, const string&);
|
||||
void createClimb(FGAIAircraft *, bool, FGAirport *, double, double, const string&);
|
||||
void createCruise(FGAIAircraft *, bool, FGAirport*, FGAirport*, double, double, double, double, const string&);
|
||||
void createDescent(FGAIAircraft *, FGAirport *, double latitude, double longitude, double speed, double alt,const string&, double distance);
|
||||
void createLanding(FGAIAircraft *, FGAirport *, const string&);
|
||||
void createPushBack(FGAIAircraft *, bool, FGAirport*, double, double, double, const std::string&, const std::string&, const std::string&);
|
||||
void createPushBackFallBack(FGAIAircraft *, bool, FGAirport*, double, double, double, const std::string&, const std::string&, const std::string&);
|
||||
void createTakeOff(FGAIAircraft *, bool, FGAirport *, double, const std::string&);
|
||||
void createClimb(FGAIAircraft *, bool, FGAirport *, double, double, const std::string&);
|
||||
void createCruise(FGAIAircraft *, bool, FGAirport*, FGAirport*, double, double, double, double, const std::string&);
|
||||
void createDescent(FGAIAircraft *, FGAirport *, double latitude, double longitude, double speed, double alt,const std::string&, double distance);
|
||||
void createLanding(FGAIAircraft *, FGAirport *, const std::string&);
|
||||
void createParking(FGAIAircraft *, FGAirport *, double radius);
|
||||
void deleteWaypoints();
|
||||
void resetWaypoints();
|
||||
|
||||
void createLandingTaxi(FGAIAircraft *, FGAirport *apt, double radius, const string& fltType, const string& acType, const string& airline);
|
||||
void createLandingTaxi(FGAIAircraft *, FGAirport *apt, double radius, const std::string& fltType, const std::string& acType, const std::string& airline);
|
||||
void createDefaultLandingTaxi(FGAIAircraft *, FGAirport* aAirport);
|
||||
void createDefaultTakeoffTaxi(FGAIAircraft *, FGAirport* aAirport, FGRunway* aRunway);
|
||||
void createTakeoffTaxi(FGAIAircraft *, bool firstFlight, FGAirport *apt, double radius, const string& fltType, const string& acType, const string& airline);
|
||||
void createTakeoffTaxi(FGAIAircraft *, bool firstFlight, FGAirport *apt, double radius, const std::string& fltType, const std::string& acType, const std::string& airline);
|
||||
|
||||
double getTurnRadius(double, bool);
|
||||
|
||||
|
|
|
@ -27,6 +27,7 @@
|
|||
#include <simgear/props/props.hxx>
|
||||
#include <simgear/props/props_io.hxx>
|
||||
|
||||
#include <Airports/simple.hxx>
|
||||
#include <Airports/runways.hxx>
|
||||
#include <Airports/dynamics.hxx>
|
||||
#include "AIAircraft.hxx"
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
#include <iostream>
|
||||
#include <simgear/route/waypoint.hxx>
|
||||
|
||||
#include <Navaids/awynet.hxx>
|
||||
#include <Airports/simple.hxx>
|
||||
#include <Airports/runways.hxx>
|
||||
#include <Airports/dynamics.hxx>
|
||||
|
||||
|
@ -40,6 +40,7 @@
|
|||
|
||||
using std::iostream;
|
||||
|
||||
/*
|
||||
void FGAIFlightPlan::evaluateRoutePart(double deplat,
|
||||
double deplon,
|
||||
double arrlat,
|
||||
|
@ -97,7 +98,7 @@ void FGAIFlightPlan::evaluateRoutePart(double deplat,
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
*/
|
||||
/*
|
||||
void FGAIFlightPlan::createCruise(bool firstFlight, FGAirport *dep,
|
||||
FGAirport *arr, double latitude,
|
||||
|
|
|
@ -23,6 +23,8 @@
|
|||
#endif
|
||||
|
||||
#include <simgear/math/sg_geodesy.hxx>
|
||||
|
||||
#include <Airports/simple.hxx>
|
||||
#include <Airports/runways.hxx>
|
||||
#include <Airports/dynamics.hxx>
|
||||
|
||||
|
|
|
@ -34,7 +34,7 @@
|
|||
#include <Traffic/TrafficMgr.hxx>
|
||||
#include <Airports/groundnetwork.hxx>
|
||||
#include <Airports/dynamics.hxx>
|
||||
|
||||
#include <Airports/simple.hxx>
|
||||
|
||||
using std::sort;
|
||||
|
||||
|
|
|
@ -30,6 +30,7 @@
|
|||
#include <simgear/debug/logstream.hxx>
|
||||
#include <simgear/route/waypoint.hxx>
|
||||
|
||||
#include <Airports/simple.hxx>
|
||||
#include <Airports/dynamics.hxx>
|
||||
|
||||
#include <AIModel/AIAircraft.hxx>
|
||||
|
|
|
@ -24,6 +24,7 @@
|
|||
#define _SIDSTAR_HXX_
|
||||
|
||||
#include <string>
|
||||
#include <map>
|
||||
|
||||
#include <simgear/misc/sg_path.hxx>
|
||||
|
||||
|
@ -36,12 +37,10 @@
|
|||
#include "runwayprefs.hxx"
|
||||
|
||||
|
||||
using std::string;
|
||||
|
||||
class FGAirport;
|
||||
|
||||
typedef vector<FGAIFlightPlan*> FlightPlanVec;
|
||||
typedef vector<FGAIFlightPlan*>::iterator FlightPlanVecIterator;
|
||||
typedef std::vector<FGAIFlightPlan*> FlightPlanVec;
|
||||
typedef std::vector<FGAIFlightPlan*>::iterator FlightPlanVecIterator;
|
||||
|
||||
typedef std::map < std::string, FlightPlanVec > FlightPlanVecMap;
|
||||
|
||||
|
@ -49,7 +48,7 @@ typedef std::map < std::string, FlightPlanVec > FlightPlanVecMap;
|
|||
class FGSidStar
|
||||
{
|
||||
private:
|
||||
string id;
|
||||
std::string id;
|
||||
bool initialized;
|
||||
FlightPlanVecMap data;
|
||||
|
||||
|
@ -57,9 +56,9 @@ class FGSidStar
|
|||
FGSidStar(FGAirport *ap);
|
||||
FGSidStar(const FGSidStar &other);
|
||||
|
||||
string getId() { return id; };
|
||||
std::string getId() { return id; };
|
||||
void load(SGPath path);
|
||||
FGAIFlightPlan *getBest(string activeRunway, double heading);
|
||||
FGAIFlightPlan *getBest(std::string activeRunway, double heading);
|
||||
};
|
||||
|
||||
|
||||
|
|
|
@ -58,6 +58,8 @@
|
|||
#include <simgear/structure/event_mgr.hxx>
|
||||
#include <simgear/misc/sg_path.hxx>
|
||||
#include <simgear/misc/sg_dir.hxx>
|
||||
#include <simgear/misc/sgstream.hxx>
|
||||
|
||||
#include <simgear/misc/interpolator.hxx>
|
||||
#include <simgear/scene/material/matlib.hxx>
|
||||
#include <simgear/scene/model/particles.hxx>
|
||||
|
@ -1072,16 +1074,6 @@ fgInitNav ()
|
|||
fixlist.init( p_fix ); // adds fixes to the DB in positioned.cxx
|
||||
|
||||
SG_LOG(SG_GENERAL, SG_INFO, " Airways");
|
||||
#if 0
|
||||
SGPath p_awy( globals->get_fg_root() );
|
||||
p_awy.append( "Navaids/awy.dat" );
|
||||
FGAirwayNetwork *awyNet = new FGAirwayNetwork;
|
||||
//cerr << "Loading Airways" << endl;
|
||||
awyNet->load (p_awy );
|
||||
awyNet->init();
|
||||
//cerr << "initializing airways" << endl;
|
||||
globals->set_airwaynet( awyNet );
|
||||
#endif
|
||||
flightgear::Airway::load();
|
||||
|
||||
return true;
|
||||
|
|
|
@ -45,7 +45,6 @@
|
|||
#include <Model/acmodel.hxx>
|
||||
#include <Model/modelmgr.hxx>
|
||||
#include <MultiPlayer/multiplaymgr.hxx>
|
||||
#include <Navaids/awynet.hxx>
|
||||
#include <Scenery/scenery.hxx>
|
||||
#include <Scenery/tilemgr.hxx>
|
||||
#include <Navaids/navlist.hxx>
|
||||
|
@ -149,9 +148,7 @@ FGGlobals::FGGlobals() :
|
|||
dmelist( NULL ),
|
||||
tacanlist( NULL ),
|
||||
carrierlist( NULL ),
|
||||
channellist( NULL ),
|
||||
airwaynet( NULL )
|
||||
|
||||
channellist( NULL )
|
||||
{
|
||||
simgear::ResourceManager::instance()->addProvider(new AircraftResourceProvider());
|
||||
}
|
||||
|
@ -199,7 +196,6 @@ FGGlobals::~FGGlobals()
|
|||
delete tacanlist;
|
||||
delete carrierlist;
|
||||
delete channellist;
|
||||
delete airwaynet;
|
||||
|
||||
soundmgr->unbind();
|
||||
delete soundmgr;
|
||||
|
|
|
@ -60,7 +60,6 @@ class FGAircraftModel;
|
|||
class FGControls;
|
||||
class FGFlightPlanDispatcher;
|
||||
class FGNavList;
|
||||
class FGAirwayNetwork;
|
||||
class FGTACANList;
|
||||
class FGModelMgr;
|
||||
class FGRouteMgr;
|
||||
|
@ -171,7 +170,6 @@ private:
|
|||
FGNavList *tacanlist;
|
||||
FGNavList *carrierlist;
|
||||
FGTACANList *channellist;
|
||||
FGAirwayNetwork *airwaynet;
|
||||
|
||||
/// roots of Aircraft trees
|
||||
string_list fg_aircraft_dirs;
|
||||
|
@ -322,10 +320,6 @@ public:
|
|||
inline FGTACANList *get_channellist() const { return channellist; }
|
||||
inline void set_channellist( FGTACANList *c ) { channellist = c; }
|
||||
|
||||
inline FGAirwayNetwork *get_airwaynet() const { return airwaynet; }
|
||||
inline void set_airwaynet( FGAirwayNetwork *a ) { airwaynet = a; }
|
||||
|
||||
|
||||
/**
|
||||
* Save the current state as the initial state.
|
||||
*/
|
||||
|
|
|
@ -13,8 +13,7 @@ libNavaids_a_SOURCES = \
|
|||
airways.hxx airways.cxx \
|
||||
route.hxx route.cxx \
|
||||
waypoint.hxx waypoint.cxx \
|
||||
procedure.hxx procedure.cxx \
|
||||
awynet.cxx awynet.hxx
|
||||
procedure.hxx procedure.cxx
|
||||
|
||||
#
|
||||
# testnavs_SOURCES = testnavs.cxx
|
||||
|
|
Loading…
Add table
Reference in a new issue