platforms.
long int offset;
double diff, part, days, hours, lst;
-#ifdef __CYGWIN32__
+ // I believe the following is Unix vs. Win32 behavior difference.
+ // If you are having problems with incorrectly positioned
+ // astronomical bodies, this is a really good place to start
+ // looking.
+#ifdef WIN32
int daylight; // not used but need to keep the compiler happy
long int timezone; // not used but need to keep the compiler happy
int mktime_is_gmt = 1;
// $Log$
+// Revision 1.6 1998/05/02 01:53:17 curt
+// Fine tuning mktime() support because of varying behavior on different
+// platforms.
+//
// Revision 1.5 1998/04/28 21:45:34 curt
// Fixed a horible bug that cause the time to be *WAY* off when compiling
// with the CygWin32 compiler. This may not yet completely address other
double sun_lon, sun_gc_lat;
// in cartesian coordiantes
- struct fgCartesianPoint fg_sunpos;
+ fgCartesianPoint3d fg_sunpos;
// (in view coordinates)
GLfloat sun_vec[4];
// $Log$
+// Revision 1.3 1998/05/02 01:53:18 curt
+// Fine tuning mktime() support because of varying behavior on different
+// platforms.
+//
// Revision 1.2 1998/04/24 00:52:31 curt
// Wrapped "#include <config.h>" in "#ifdef HAVE_CONFIG_H"
// Fog color fixes.
#include <Main/views.hxx>
#include <Math/fg_geodesy.h>
#include <Math/mat3.h>
-#include <Math/polar.h>
+#include <Math/polar3d.h>
#include <Math/vector.h>
#include <Scenery/scenery.hxx>
fgTIME *t;
fgVIEW *v;
MAT3vec nup, nsun, v0;
+ fgPolarPoint3d p;
double sun_gd_lat, sl_radius;
double ntmp;
fgGeodToGeoc(sun_gd_lat, 0.0, &sl_radius, &l->sun_gc_lat);
- l->fg_sunpos = fgPolarToCart(l->sun_lon, l->sun_gc_lat, sl_radius);
+ p.lon = l->sun_lon;
+ p.lat = l->sun_gc_lat;
+ p.radius = sl_radius;
+ l->fg_sunpos = fgPolarToCart3d(p);
printf( " t->cur_time = %ld\n", t->cur_time);
printf( " Sun Geodetic lat = %.5f Geocentric lat = %.5f\n",
// $Log$
+// Revision 1.8 1998/05/02 01:53:18 curt
+// Fine tuning mktime() support because of varying behavior on different
+// platforms.
+//
// Revision 1.7 1998/04/30 12:36:05 curt
// C++-ifying a couple source files.
//