]> git.mxchange.org Git - flightgear.git/commitdiff
Clean up naming of the 'point on runway' helpers, to get rid of the confusing
authorjmt <jmt>
Sat, 3 Jan 2009 16:15:48 +0000 (16:15 +0000)
committerTim Moore <timoore@redhat.com>
Wed, 7 Jan 2009 09:22:53 +0000 (10:22 +0100)
notion of a 'displacedThreshold'. Now there's just a real threshold,
displaced or otherwise, and people who care about the paved area can use
'begin' and 'end'. Thanks to John Denker for pointing out the confusion this
leads to. Using 'end' also gets rid of the 'reverseThreshold' name, which was
clearly a bad choice of mine.

src/AIModel/AIFlightPlanCreate.cxx
src/Airports/runways.cxx
src/Airports/runways.hxx

index f48110b72df63aab9c8f5fc70beef88f177962d9..35d2c75d163684f96bcaf41f077fd299c279de1e 100644 (file)
@@ -363,7 +363,7 @@ void FGAIFlightPlan::createTakeOff(bool firstFlight, FGAirport *apt, double spee
  wpt->on_ground = false;
  waypoints.push_back(wpt);
 
- wpt = cloneWithPos(wpt, "3000 ft", rwy->reverseThreshold());
+ wpt = cloneWithPos(wpt, "3000 ft", rwy->end());
  wpt->altitude  = airportElev+3000;
  waypoints.push_back(wpt);
 
@@ -441,7 +441,7 @@ void FGAIFlightPlan::createLanding(FGAirport *apt)
   waypoint *wpt;
   double aptElev = apt->getElevation();
   //Runway Threshold
-  wpt = createOnGround("Threshold", rwy->displacedThreshold(), aptElev, 150);
+  wpt = createOnGround("Threshold", rwy->threshold(), aptElev, 150);
   wpt->crossat = apt->getElevation();
   waypoints.push_back(wpt); 
 
index 5adfba4f8ac19ec9910a4797b5282526fe17747b..fc70d8384237883cf6920471a80d7f7eb75d0576 100644 (file)
@@ -120,17 +120,17 @@ double FGRunway::score(double aLengthWt, double aWidthWt, double aSurfaceWt) con
   return _length * aLengthWt + _width * aWidthWt + surface * aSurfaceWt + 1e-20;
 }
 
-SGGeod FGRunway::threshold() const
+SGGeod FGRunway::begin() const
 {
   return pointOnCenterline(0.0);
 }
 
-SGGeod FGRunway::reverseThreshold() const
+SGGeod FGRunway::end() const
 {
   return pointOnCenterline(lengthM());
 }
 
-SGGeod FGRunway::displacedThreshold() const
+SGGeod FGRunway::threshold() const
 {
   return pointOnCenterline(_displ_thresh * SG_FEET_TO_METER);
 }
index ae2610c8b06f41521346cd206b868260b4a170d7..b61b6a079ec6c45de16792b35b44380bf9e3e859 100644 (file)
@@ -68,21 +68,21 @@ public:
   { return _reciprocal; }
 
   /**
-   * Get the runway threshold point - this is syntatic sugar, equivalent to
+   * Get the runway begining point - this is syntatic sugar, equivalent to
    * calling pointOnCenterline(0.0);
    */
-  SGGeod threshold() const;
+  SGGeod begin() const;
   
   /**
    * Get the (possibly displaced) threshold point.
    */
-  SGGeod displacedThreshold() const;
+  SGGeod threshold() const;
   
   /**
-   * Get the opposite threshold - this is equivalent to calling
+   * Get the 'far' end - this is equivalent to calling
    * pointOnCenterline(lengthFt());
    */
-  SGGeod reverseThreshold() const;
+  SGGeod end() const;
   
   double displacedThresholdM() const
   { return _displ_thresh * SG_FEET_TO_METER; }