]> git.mxchange.org Git - flightgear.git/commitdiff
FG_ to SG_ namespace changes.
authorcurt <curt>
Sat, 24 Mar 2001 03:10:40 +0000 (03:10 +0000)
committercurt <curt>
Sat, 24 Mar 2001 03:10:40 +0000 (03:10 +0000)
src/FDM/LaRCsim.cxx
src/GUI/mouse.cxx
src/Main/main.cxx
src/Time/light.cxx
src/Time/moonpos.cxx
src/Time/sunpos.cxx

index 209bd345f31b87fdc68123a83d90d51211080e21..2903f92d78b0d7940c6336d6ac243e592a053899 100644 (file)
@@ -474,12 +474,12 @@ bool FGLaRCsim::copy_from_LaRCsim() {
            << " radius_to_vehicle = " << Radius_to_vehicle );
 
     double tmp_lon_geoc = Lon_geocentric;
-    while ( tmp_lon_geoc < -SGD_PI ) { tmp_lon_geoc += SG_2PI; }
-    while ( tmp_lon_geoc > SGD_PI ) { tmp_lon_geoc -= SG_2PI; }
+    while ( tmp_lon_geoc < -SGD_PI ) { tmp_lon_geoc += SGD_2PI; }
+    while ( tmp_lon_geoc > SGD_PI ) { tmp_lon_geoc -= SGD_2PI; }
 
     double tmp_lon = Longitude;
-    while ( tmp_lon < -SGD_PI ) { tmp_lon += SG_2PI; }
-    while ( tmp_lon > SGD_PI ) { tmp_lon -= SG_2PI; }
+    while ( tmp_lon < -SGD_PI ) { tmp_lon += SGD_2PI; }
+    while ( tmp_lon > SGD_PI ) { tmp_lon -= SGD_2PI; }
 
     // Positions
     _set_Geocentric_Position( Lat_geocentric, tmp_lon_geoc, 
index 258b619f4f061c62a4071b42c3ef90b3b7a980ca..b868c12421140d9716a432eecb854fd6a8939bea 100644 (file)
@@ -378,12 +378,12 @@ void guiMotionFunc ( int x, int y )
                 // this could be done in above quat
                 // but requires redoing view pipeline
                 offset = globals->get_current_view()->get_goal_view_offset();
-                offset += ((_mX - x) * SG_2PI / W );
+                offset += ((_mX - x) * SGD_2PI / W );
                 while (offset < 0.0) {
-                    offset += SG_2PI;
+                    offset += SGD_2PI;
                 }
-                while (offset > SG_2PI) {
-                    offset -= SG_2PI;
+                while (offset > SGD_2PI) {
+                    offset -= SGD_2PI;
                 }
                 globals->get_current_view()->set_goal_view_offset(offset);
 #ifdef NO_SMOOTH_MOUSE_VIEW
index 69291af598f46505660d278df21549906a57e8af..aa5ef3958ecb1f06d3c2879cace10905f3e9a6ed 100644 (file)
@@ -814,10 +814,10 @@ void fgUpdateTimeDepCalcs() {
                    v->inc_view_offset( 0.01 );
                }
            }
-           if ( v->get_view_offset() > SG_2PI ) {
-               v->inc_view_offset( -SG_2PI );
+           if ( v->get_view_offset() > SGD_2PI ) {
+               v->inc_view_offset( -SGD_2PI );
            } else if ( v->get_view_offset() < 0 ) {
-               v->inc_view_offset( SG_2PI );
+               v->inc_view_offset( SGD_2PI );
            }
        }
     }
@@ -826,10 +826,10 @@ void fgUpdateTimeDepCalcs() {
        - (cur_fdm_state->get_Psi() -
           globals->get_current_view()->get_view_offset() );
     while ( tmp < 0.0 ) {
-       tmp += SG_2PI;
+       tmp += SGD_2PI;
     }
-    while ( tmp > SG_2PI ) {
-       tmp -= SG_2PI;
+    while ( tmp > SGD_2PI ) {
+       tmp -= SGD_2PI;
     }
     /* printf("Psi = %.2f, viewoffset = %.2f sunrot = %.2f rottosun = %.2f\n",
           FG_Psi * RAD_TO_DEG, current_view.view_offset * RAD_TO_DEG, 
index fc145b480a99954b2a37e9ea61ee960bccc67183..be46d20ca43271852a248248a4fc8a28a70801b4 100644 (file)
@@ -173,10 +173,10 @@ void fgLIGHT::UpdateAdjFog( void ) {
        rotation += SGD_PI;
     }
     while ( rotation < 0 ) {
-       rotation += SG_2PI;
+       rotation += SGD_2PI;
     }
-    while ( rotation > SG_2PI ) {
-       rotation -= SG_2PI;
+    while ( rotation > SGD_2PI ) {
+       rotation -= SGD_2PI;
     }
     rotation *= RAD_TO_DEG;
     // fgPrintf( FG_EVENT, FG_INFO, 
index e038c21cdf59812872ed36e0c688e720571148c2..f63a32bdd0e719c03d7ec2058bfa872d8d99ef91 100644 (file)
@@ -99,8 +99,8 @@
  * Eccentricity (eccentricity of orbit)                0.016713
  */
 
-#define Epsilon_g    (279.403303*(SG_2PI/360))
-#define OmegaBar_g   (282.768422*(SG_2PI/360))
+#define Epsilon_g    (279.403303*(SGD_2PI/360))
+#define OmegaBar_g   (282.768422*(SGD_2PI/360))
 #define Eccentricity (0.016713)
 
 /*
  * 1990.0 (computed as 23.440592 degrees according to the method given
  * in duffett-smith, section 27)
  */
-#define MeanObliquity (23.440592*(SG_2PI/360))
+#define MeanObliquity (23.440592*(SGD_2PI/360))
 
 /* static double solve_keplers_equation(double); */
 /* static double moon_ecliptic_longitude(time_t); */
@@ -283,12 +283,12 @@ void fgMoonPosition(time_t ssue, double *lon, double *lat) {
 
     ecliptic_to_equatorial( globals->get_ephem()->get_moon()->getLon(),
                            0.0, &alpha, &delta );
-    tmp = alpha - (SG_2PI/24)*GST(ssue);
+    tmp = alpha - (SGD_2PI/24)*GST(ssue);
     if (tmp < -SGD_PI) {
-       do tmp += SG_2PI;
+       do tmp += SGD_2PI;
        while (tmp < -SGD_PI);
     } else if (tmp > SGD_PI) {
-       do tmp -= SG_2PI;
+       do tmp -= SGD_2PI;
        while (tmp < -SGD_PI);
     }
 
@@ -318,12 +318,12 @@ static void fgMoonPositionGST(double gst, double *lon, double *lat) {
                            &alpha,  &delta );
 
 //    tmp = alpha - (SG_2PI/24)*GST(ssue);
-    tmp = alpha - (SG_2PI/24)*gst;     
+    tmp = alpha - (SGD_2PI/24)*gst;    
     if (tmp < -SGD_PI) {
-       do tmp += SG_2PI;
+       do tmp += SGD_2PI;
        while (tmp < -SGD_PI);
     } else if (tmp > SGD_PI) {
-       do tmp -= SG_2PI;
+       do tmp -= SGD_2PI;
        while (tmp < -SGD_PI);
     }
 
index 49a1f8aafa304f3d66ef583b699dfa5af0f22115..3c1c3434f3978ef65d6bddf212b68d6f5d210b87 100644 (file)
@@ -68,7 +68,7 @@
 #include "sunpos.hxx"
 
 // #undef E // should no longer be needed
-#define MeanObliquity (23.440592*(SG_2PI/360))
+#define MeanObliquity (23.440592*(SGD_2PI/360))
 
 static void   ecliptic_to_equatorial(double, double, double *, double *);
 static double julian_date(int, int, int);
@@ -191,12 +191,12 @@ void fgSunPosition(time_t ssue, double *lon, double *lat) {
 
     ecliptic_to_equatorial( globals->get_ephem()->get_sun()->getLon(),
                            0.0, &alpha, &delta );
-    tmp = alpha - (SG_2PI/24)*GST(ssue);
+    tmp = alpha - (SGD_2PI/24)*GST(ssue);
     if (tmp < -SGD_PI) {
-       do tmp += SG_2PI;
+       do tmp += SGD_2PI;
        while (tmp < -SGD_PI);
     } else if (tmp > SGD_PI) {
-       do tmp -= SG_2PI;
+       do tmp -= SGD_2PI;
        while (tmp < -SGD_PI);
     }
 
@@ -225,13 +225,13 @@ static void fgSunPositionGST(double gst, double *lon, double *lat) {
                            globals->get_ephem()->get_sun()->getLat(),
                            &alpha, &delta );
 
-//    tmp = alpha - (SG_2PI/24)*GST(ssue);
-    tmp = alpha - (SG_2PI/24)*gst;     
+//    tmp = alpha - (SGD_2PI/24)*GST(ssue);
+    tmp = alpha - (SGD_2PI/24)*gst;    
     if (tmp < -SGD_PI) {
-       do tmp += SG_2PI;
+       do tmp += SGD_2PI;
        while (tmp < -SGD_PI);
     } else if (tmp > SGD_PI) {
-       do tmp -= SG_2PI;
+       do tmp -= SGD_2PI;
        while (tmp < -SGD_PI);
     }