**************************************************************************/
-#ifndef FG_TIME_H
-#define FG_TIME_H
+#ifndef _FG_TIME_H
+#define _FG_TIME_H
-#ifdef WIN32
+#include <config.h>
+
+#ifdef HAVE_WINDOWS_H
# include <windows.h>
#endif
#include <GL/glut.h>
#include <time.h>
-#include "../Include/types.h"
-#include "../Flight/flight.h"
+#include <Include/fg_types.h>
+#include <Flight/flight.h>
/* Define a structure containing global time parameters */
extern struct fgLIGHT cur_light_params;
+typedef struct fg_timestamp_t {
+ long seconds;
+ long millis;
+} fg_timestamp;
+
+
+/* Portability wrap to get current time. */
+void timestamp(fg_timestamp *timestamp);
+
+/* Return duration in millis from first to last */
+long timediff(fg_timestamp *first, fg_timestamp *last);
+
+/* Return new timestamp given a time stamp and an interval to add in */
+void timesum(fg_timestamp *res, fg_timestamp *start, long millis);
/* Initialize the time dependent variables */
void fgTimeInit(struct fgTIME *t);
/* Update the time dependent variables */
-void fgTimeUpdate(struct fgFLIGHT *f, struct fgTIME *t);
+void fgTimeUpdate(fgFLIGHT *f, struct fgTIME *t);
-#endif /* FG_TIME_H */
+#endif /* _FG_TIME_H */
/* $Log$
-/* Revision 1.12 1998/01/05 18:44:37 curt
-/* Add an option to advance/decrease time from keyboard.
+/* Revision 1.18 1998/04/08 23:35:40 curt
+/* Tweaks to Gnu automake/autoconf system.
/*
+ * Revision 1.17 1998/04/03 22:12:56 curt
+ * Converting to Gnu autoconf system.
+ * Centralized time handling differences.
+ *
+ * Revision 1.16 1998/02/07 15:29:47 curt
+ * Incorporated HUD changes and struct/typedef changes from Charlie Hotchkiss
+ * <chotchkiss@namg.us.anritsu.com>
+ *
+ * Revision 1.15 1998/01/27 00:48:06 curt
+ * Incorporated Paul Bleisch's <bleisch@chromatic.com> new debug message
+ * system and commandline/config file processing code.
+ *
+ * Revision 1.14 1998/01/22 02:59:43 curt
+ * Changed #ifdef FILE_H to #ifdef _FILE_H
+ *
+ * Revision 1.13 1998/01/19 19:27:20 curt
+ * Merged in make system changes from Bob Kuehne <rpk@sgi.com>
+ * This should simplify things tremendously.
+ *
+ * Revision 1.12 1998/01/05 18:44:37 curt
+ * Add an option to advance/decrease time from keyboard.
+ *
* Revision 1.11 1997/12/19 23:35:07 curt
* Lot's of tweaking with sky rendering and lighting.
*