]> git.mxchange.org Git - flightgear.git/blobdiff - src/Navaids/nav.hxx
- adjusted for no-value constructor for FGPanel
[flightgear.git] / src / Navaids / nav.hxx
index bdd83ca2e202039110d057e4eff65b711d40f734..967b6a3cc66e3278fdcf05dca5ee2f361b2a5b83 100644 (file)
 
 #include <simgear/compiler.h>
 #include <simgear/math/sg_geodesy.hxx>
-#include <simgear/misc/fgstream.hxx>
+#include <simgear/misc/sgstream.hxx>
 #include <simgear/magvar/magvar.hxx>
 #include <simgear/timing/sg_time.hxx>
 
 #ifdef SG_HAVE_STD_INCLUDES
 #  include <istream>
-#elif defined( FG_HAVE_NATIVE_SGI_COMPILERS )
+#elif defined( SG_HAVE_NATIVE_SGI_COMPILERS )
 #  include <iostream.h>
 #elif defined( __BORLANDC__ )
 #  include <iostream>
@@ -42,8 +42,8 @@
 #  include <istream.h>
 #endif
 
-#if ! defined( FG_HAVE_NATIVE_SGI_COMPILERS )
-FG_USING_STD(istream);
+#if ! defined( SG_HAVE_NATIVE_SGI_COMPILERS )
+SG_USING_STD(istream);
 #endif
 
 
@@ -129,9 +129,9 @@ operator >> ( istream& in, FGNav& n )
        // cout << "lat = " << n.lat << " lon = " << n.lon << " elev = " 
        //      << n.elev << " JD = " 
        //      << julian_date << endl;
-       n.magvar = sgGetMagVar(n.lon * DEG_TO_RAD, n.lat * DEG_TO_RAD,
-                               n.elev * FEET_TO_METER,
-                               julian_date) * RAD_TO_DEG;
+       n.magvar = sgGetMagVar(n.lon * SGD_DEGREES_TO_RADIANS, n.lat * SGD_DEGREES_TO_RADIANS,
+                               n.elev * SG_FEET_TO_METER,
+                               julian_date) * SGD_RADIANS_TO_DEGREES;
        // cout << "Default variation at " << n.lon << ',' << n.lat
        //      << " is " << var << endl;
 #if 0
@@ -156,7 +156,7 @@ operator >> ( istream& in, FGNav& n )
     // cout << n.ident << " " << n.magvar << endl;
 
     // generate cartesian coordinates
-    Point3D geod( n.lon * DEG_TO_RAD, n.lat * DEG_TO_RAD, n.elev );
+    Point3D geod( n.lon * SGD_DEGREES_TO_RADIANS, n.lat * SGD_DEGREES_TO_RADIANS, n.elev );
     Point3D cart = sgGeodToCart( geod );
     n.x = cart.x();
     n.y = cart.y();