#include "waypoint.hxx"
#include <simgear/structure/exception.hxx>
-#include <simgear/route/waypoint.hxx>
#include <Airports/simple.hxx>
#include <Airports/runways.hxx>
namespace flightgear
{
-BasicWaypt::BasicWaypt(const SGGeod& aPos, const string& aIdent, Route* aOwner) :
+BasicWaypt::BasicWaypt(const SGGeod& aPos, const string& aIdent, RouteBase* aOwner) :
Waypt(aOwner),
_pos(aPos),
_ident(aIdent)
}
}
-BasicWaypt::BasicWaypt(const SGWayPoint& aWP, Route* aOwner) :
- Waypt(aOwner),
- _pos(aWP.get_target()),
- _ident(aWP.get_id())
-{
-}
-
-BasicWaypt::BasicWaypt(Route* aOwner) :
+BasicWaypt::BasicWaypt(RouteBase* aOwner) :
Waypt(aOwner)
{
}
//////////////////////////////////////////////////////////////////////////////
-NavaidWaypoint::NavaidWaypoint(FGPositioned* aPos, Route* aOwner) :
+NavaidWaypoint::NavaidWaypoint(FGPositioned* aPos, RouteBase* aOwner) :
Waypt(aOwner),
_navaid(aPos)
{
if (aPos->type() == FGPositioned::RUNWAY) {
- SG_LOG(SG_GENERAL, SG_WARN, "sure you don't want to be building a runway waypt here?");
+ SG_LOG(SG_NAVAID, SG_WARN, "sure you don't want to be building a runway waypt here?");
}
}
-NavaidWaypoint::NavaidWaypoint(Route* aOwner) :
+NavaidWaypoint::NavaidWaypoint(RouteBase* aOwner) :
Waypt(aOwner)
{
}
aProp->setDoubleValue("lat", _navaid->geod().getLatitudeDeg());
}
-OffsetNavaidWaypoint::OffsetNavaidWaypoint(FGPositioned* aPos, Route* aOwner,
+OffsetNavaidWaypoint::OffsetNavaidWaypoint(FGPositioned* aPos, RouteBase* aOwner,
double aRadial, double aDistNm) :
NavaidWaypoint(aPos, aOwner),
_radial(aRadial),
init();
}
-OffsetNavaidWaypoint::OffsetNavaidWaypoint(Route* aOwner) :
+OffsetNavaidWaypoint::OffsetNavaidWaypoint(RouteBase* aOwner) :
NavaidWaypoint(aOwner)
{
}
/////////////////////////////////////////////////////////////////////////////
-RunwayWaypt::RunwayWaypt(FGRunway* aPos, Route* aOwner) :
+RunwayWaypt::RunwayWaypt(FGRunway* aPos, RouteBase* aOwner) :
Waypt(aOwner),
_runway(aPos)
{
}
-RunwayWaypt::RunwayWaypt(Route* aOwner) :
+RunwayWaypt::RunwayWaypt(RouteBase* aOwner) :
Waypt(aOwner)
{
}
/////////////////////////////////////////////////////////////////////////////
-Hold::Hold(const SGGeod& aPos, const string& aIdent, Route* aOwner) :
+Hold::Hold(const SGGeod& aPos, const string& aIdent, RouteBase* aOwner) :
BasicWaypt(aPos, aIdent, aOwner),
_righthanded(true),
_isDistance(false)
setFlag(WPT_DYNAMIC);
}
-Hold::Hold(Route* aOwner) :
+Hold::Hold(RouteBase* aOwner) :
BasicWaypt(aOwner),
_righthanded(true),
_isDistance(false)
/////////////////////////////////////////////////////////////////////////////
-HeadingToAltitude::HeadingToAltitude(Route* aOwner, const string& aIdent,
+HeadingToAltitude::HeadingToAltitude(RouteBase* aOwner, const string& aIdent,
double aMagHdg) :
Waypt(aOwner),
_ident(aIdent),
setFlag(WPT_DYNAMIC);
}
-HeadingToAltitude::HeadingToAltitude(Route* aOwner) :
+HeadingToAltitude::HeadingToAltitude(RouteBase* aOwner) :
Waypt(aOwner)
{
}
/////////////////////////////////////////////////////////////////////////////
-DMEIntercept::DMEIntercept(Route* aOwner, const string& aIdent, const SGGeod& aPos,
+DMEIntercept::DMEIntercept(RouteBase* aOwner, const string& aIdent, const SGGeod& aPos,
double aCourseDeg, double aDistanceNm) :
Waypt(aOwner),
_ident(aIdent),
setFlag(WPT_DYNAMIC);
}
-DMEIntercept::DMEIntercept(Route* aOwner) :
+DMEIntercept::DMEIntercept(RouteBase* aOwner) :
Waypt(aOwner)
{
}
/////////////////////////////////////////////////////////////////////////////
-RadialIntercept::RadialIntercept(Route* aOwner, const string& aIdent, const SGGeod& aPos,
+RadialIntercept::RadialIntercept(RouteBase* aOwner, const string& aIdent, const SGGeod& aPos,
double aCourseDeg, double aRadial) :
Waypt(aOwner),
_ident(aIdent),
setFlag(WPT_DYNAMIC);
}
-RadialIntercept::RadialIntercept(Route* aOwner) :
+RadialIntercept::RadialIntercept(RouteBase* aOwner) :
Waypt(aOwner)
{
}
/////////////////////////////////////////////////////////////////////////////
-ATCVectors::ATCVectors(Route* aOwner, FGAirport* aFacility) :
+ATCVectors::ATCVectors(RouteBase* aOwner, FGAirport* aFacility) :
Waypt(aOwner),
_facility(aFacility)
{
{
}
-ATCVectors::ATCVectors(Route* aOwner) :
+ATCVectors::ATCVectors(RouteBase* aOwner) :
Waypt(aOwner)
{
}