1
0
Fork 0

Tons of little changes to clean up the code and to remove fatal errors

when building with the c++ compiler.
This commit is contained in:
curt 1998-01-19 18:40:15 +00:00
parent a9fdc0e341
commit f1ec224b73
59 changed files with 535 additions and 304 deletions

View file

@ -8,6 +8,17 @@ moon.o: moon.c ../XGL/xgl.h orbits.h ../Time/fg_time.h \
../Include/general.h ../Main/views.h ../Main/../Include/types.h \
../Main/../Flight/flight.h ../Main/../Math/mat3.h \
../Main/../Time/fg_time.h
old_astro.o: old_astro.c ../XGL/xgl.h old_astro.h stars.h moon.h \
orbits.h ../Time/fg_time.h ../Time/../Include/types.h \
../Time/../Flight/flight.h ../Time/../Flight/Slew/slew.h \
../Time/../Flight/LaRCsim/ls_interface.h \
../Time/../Flight/LaRCsim/../flight.h planets.h sun.h \
../Include/constants.h ../Include/general.h ../Main/views.h \
../Main/../Include/types.h ../Main/../Flight/flight.h \
../Main/../Math/mat3.h ../Main/../Time/fg_time.h \
../Aircraft/aircraft.h ../Aircraft/../Flight/flight.h \
../Aircraft/../Controls/controls.h \
../Aircraft/../Controls/../Include/limits.h
orbits.o: orbits.c orbits.h ../Time/fg_time.h \
../Time/../Include/types.h ../Time/../Flight/flight.h \
../Time/../Flight/Slew/slew.h \

View file

@ -257,7 +257,7 @@ struct CelestialCoord fgCalculateMoon(struct OrbElements params,
}
void fgMoonInit() {
void fgMoonInit( void ) {
struct fgLIGHT *l;
static int dl_exists = 0;
@ -298,7 +298,7 @@ void fgMoonInit() {
/* Draw the moon */
void fgMoonRender() {
void fgMoonRender( void ) {
struct fgLIGHT *l;
GLfloat white[4] = { 1.0, 1.0, 1.0, 1.0 };
@ -320,9 +320,13 @@ void fgMoonRender() {
/* $Log$
/* Revision 1.1 1998/01/07 03:16:16 curt
/* Moved from .../Src/Scenery/ to .../Src/Astro/
/* Revision 1.2 1998/01/19 18:40:16 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.1 1998/01/07 03:16:16 curt
* Moved from .../Src/Scenery/ to .../Src/Astro/
*
* Revision 1.16 1998/01/06 01:20:24 curt
* Tweaks to help building with MSVC++
*

View file

@ -36,10 +36,10 @@
/* Initialize the Moon Display management Subsystem */
void fgMoonInit();
void fgMoonInit( void );
/* Draw the Stars */
void fgMoonRender();
void fgMoonRender( void );
struct CelestialCoord fgCalculateMoon(struct OrbElements Params,
struct OrbElements sunParams,
@ -51,9 +51,13 @@ extern struct OrbElements pltOrbElements[9];
/* $Log$
/* Revision 1.1 1998/01/07 03:16:16 curt
/* Moved from .../Src/Scenery/ to .../Src/Astro/
/* Revision 1.2 1998/01/19 18:40:17 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.1 1998/01/07 03:16:16 curt
* Moved from .../Src/Scenery/ to .../Src/Astro/
*
* Revision 1.4 1997/12/11 04:43:56 curt
* Fixed sun vector and lighting problems. I thing the moon is now lit
* correctly.

View file

@ -72,7 +72,7 @@ static float outer_color[12][4];
/* Calculate the sky structure vertices */
void fgSkyVerticesInit() {
void fgSkyVerticesInit( void ) {
float theta;
int i;
@ -101,7 +101,7 @@ void fgSkyVerticesInit() {
/* (Re)calculate the sky colors at each vertex */
void fgSkyColorsInit() {
void fgSkyColorsInit( void ) {
struct fgLIGHT *l;
float sun_angle, diff;
float outer_param[3], outer_amt[3], outer_diff[3];
@ -224,7 +224,7 @@ void fgSkyColorsInit() {
/* Initialize the sky structure and colors */
void fgSkyInit() {
void fgSkyInit( void ) {
printf("Initializing the sky\n");
fgSkyVerticesInit();
@ -236,7 +236,7 @@ void fgSkyInit() {
/* Draw the Sky */
void fgSkyRender() {
void fgSkyRender( void ) {
struct fgFLIGHT *f;
struct fgLIGHT *l;
struct fgVIEW *v;
@ -329,9 +329,13 @@ void fgSkyRender() {
/* $Log$
/* Revision 1.1 1998/01/07 03:16:19 curt
/* Moved from .../Src/Scenery/ to .../Src/Astro/
/* Revision 1.2 1998/01/19 18:40:17 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.1 1998/01/07 03:16:19 curt
* Moved from .../Src/Scenery/ to .../Src/Astro/
*
* Revision 1.11 1997/12/30 22:22:38 curt
* Further integration of event manager.
*

View file

@ -25,19 +25,23 @@
/* (Re)generate the display list */
void fgSkyInit();
void fgSkyInit( void );
/* (Re)calculate the sky colors at each vertex */
void fgSkyColorsInit();
void fgSkyColorsInit( void );
/* Draw the Sky */
void fgSkyRender();
void fgSkyRender( void );
/* $Log$
/* Revision 1.1 1998/01/07 03:16:19 curt
/* Moved from .../Src/Scenery/ to .../Src/Astro/
/* Revision 1.2 1998/01/19 18:40:17 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.1 1998/01/07 03:16:19 curt
* Moved from .../Src/Scenery/ to .../Src/Astro/
*
* Revision 1.2 1997/12/22 23:45:49 curt
* First stab at sunset/sunrise sky glow effects.
*

View file

@ -56,7 +56,7 @@
/* Initialize the Star Management Subsystem */
void fgStarsInit() {
void fgStarsInit( void ) {
FILE *fd;
struct fgGENERAL *g;
struct CelestialCoord pltPos;
@ -237,7 +237,7 @@ void fgStarsInit() {
/* Draw the Stars */
void fgStarsRender() {
void fgStarsRender( void ) {
struct fgFLIGHT *f;
struct fgVIEW *v;
struct fgLIGHT *l;
@ -276,9 +276,13 @@ void fgStarsRender() {
/* $Log$
/* Revision 1.1 1998/01/07 03:16:20 curt
/* Moved from .../Src/Scenery/ to .../Src/Astro/
/* Revision 1.2 1998/01/19 18:40:18 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.1 1998/01/07 03:16:20 curt
* Moved from .../Src/Scenery/ to .../Src/Astro/
*
* Revision 1.24 1997/12/30 22:22:39 curt
* Further integration of event manager.
*

View file

@ -33,10 +33,10 @@
#define FG_MIN_STAR_MAG 0.738750 /* magnitude of weakest star we'll display */
/* Initialize the Star Management Subsystem */
void fgStarsInit();
void fgStarsInit( void );
/* Draw the Stars */
void fgStarsRender();
void fgStarsRender( void );
extern struct OrbElements pltOrbElements[9];
extern struct fgTIME cur_time_params;
@ -44,9 +44,13 @@ extern struct fgTIME cur_time_params;
/* $Log$
/* Revision 1.1 1998/01/07 03:16:20 curt
/* Moved from .../Src/Scenery/ to .../Src/Astro/
/* Revision 1.2 1998/01/19 18:40:18 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.1 1998/01/07 03:16:20 curt
* Moved from .../Src/Scenery/ to .../Src/Astro/
*
* Revision 1.6 1997/10/25 03:18:29 curt
* Incorporated sun, moon, and planet position and rendering code contributed
* by Durk Talsma.

View file

@ -94,7 +94,7 @@ struct CelestialCoord fgCalculateSun(struct OrbElements params, struct fgTIME t)
/* Initialize the Sun */
void fgSunInit() {
void fgSunInit( void ) {
static int dl_exists = 0;
printf(" Initializing the Sun\n");
@ -126,7 +126,7 @@ void fgSunInit() {
/* Draw the Sun */
void fgSunRender() {
void fgSunRender( void ) {
struct fgVIEW *v;
struct fgTIME *t;
struct fgLIGHT *l;
@ -190,9 +190,13 @@ void fgSunRender() {
/* $Log$
/* Revision 1.1 1998/01/07 03:16:20 curt
/* Moved from .../Src/Scenery/ to .../Src/Astro/
/* Revision 1.2 1998/01/19 18:40:18 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.1 1998/01/07 03:16:20 curt
* Moved from .../Src/Scenery/ to .../Src/Astro/
*
* Revision 1.12 1998/01/05 18:44:36 curt
* Add an option to advance/decrease time from keyboard.
*

View file

@ -31,19 +31,23 @@ struct SunPos fgCalcSunPos(struct OrbElements sunParams);
extern struct OrbElements pltOrbElements[9];
/* Initialize the Sun */
void fgSunInit();
void fgSunInit( void );
/* Draw the Sun */
void fgSunRender();
void fgSunRender( void );
#endif /* SUN_H */
/* $Log$
/* Revision 1.1 1998/01/07 03:16:21 curt
/* Moved from .../Src/Scenery/ to .../Src/Astro/
/* Revision 1.2 1998/01/19 18:40:19 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.1 1998/01/07 03:16:21 curt
* Moved from .../Src/Scenery/ to .../Src/Astro/
*
* Revision 1.3 1997/12/11 04:43:56 curt
* Fixed sun vector and lighting problems. I thing the moon is now lit
* correctly.

View file

@ -79,7 +79,7 @@ struct fgCOCKPIT *fgCockpitAddHUD( struct fgCOCKPIT *cockpit, struct HUD *hud )
cockpit->hud = hud;
}
void fgCockpitUpdate()
void fgCockpitUpdate( void )
{
printf( "Cockpit: code %d status %d\n", aircraft_cockpit->code, aircraft_cockpit->status );
@ -90,9 +90,13 @@ void fgCockpitUpdate()
/* $Log$
/* Revision 1.4 1997/12/30 20:47:34 curt
/* Integrated new event manager with subsystem initializations.
/* Revision 1.5 1998/01/19 18:40:19 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.4 1997/12/30 20:47:34 curt
* Integrated new event manager with subsystem initializations.
*
* Revision 1.3 1997/12/15 23:54:33 curt
* Add xgl wrappers for debugging.
* Generate terrain normals on the fly.

View file

@ -39,14 +39,18 @@ struct fgCOCKPIT {
};
struct fgCOCKPIT *fgCockpitInit( struct fgAIRCRAFT cur_aircraft );
void fgCockpitUpdate();
void fgCockpitUpdate( void );
/* $Log$
/* Revision 1.2 1997/12/10 22:37:39 curt
/* Prepended "fg" on the name of all global structures that didn't have it yet.
/* i.e. "struct WEATHER {}" became "struct fgWEATHER {}"
/* Revision 1.3 1998/01/19 18:40:19 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.2 1997/12/10 22:37:39 curt
* Prepended "fg" on the name of all global structures that didn't have it yet.
* i.e. "struct WEATHER {}" became "struct fgWEATHER {}"
*
* Revision 1.1 1997/08/29 18:03:21 curt
* Initial revision.
*

View file

@ -18,13 +18,3 @@ hud.o: hud.c hud.h ../Aircraft/aircraft.h \
../Scenery/scenery.h ../Scenery/../Include/types.h ../Math/mat3.h \
../Math/polar.h ../Math/../Include/types.h ../Time/fg_timer.h \
../Math/fg_random.h ../Weather/weather.h
test.o: test.c test.h ../Aircraft/aircraft.h \
../Aircraft/../Flight/flight.h ../Aircraft/../Flight/Slew/slew.h \
../Aircraft/../Flight/LaRCsim/ls_interface.h \
../Aircraft/../Flight/LaRCsim/../flight.h \
../Aircraft/../Controls/controls.h \
../Aircraft/../Controls/../Include/limits.h ../Flight/flight.h \
../Controls/controls.h ../Include/constants.h ../Scenery/mesh.h \
../Scenery/scenery.h ../Scenery/../Include/types.h ../Math/mat3.h \
../Math/polar.h ../Math/../Include/types.h ../Time/fg_timer.h \
../Math/fg_random.h ../Weather/weather.h

View file

@ -462,7 +462,7 @@ static void drawlabel( struct HUD_label label )
}
double get_speed()
double get_speed( void )
{
struct fgFLIGHT *f;
@ -470,7 +470,7 @@ double get_speed()
return( FG_V_equiv_kts );
}
double get_aoa()
double get_aoa( void )
{
struct fgFLIGHT *f;
@ -478,7 +478,7 @@ double get_aoa()
return( FG_Gamma_vert_rad*RAD_TO_DEG );
}
double get_roll()
double get_roll( void )
{
struct fgFLIGHT *f;
@ -486,7 +486,7 @@ double get_roll()
return( FG_Phi );
}
double get_pitch()
double get_pitch( void )
{
struct fgFLIGHT *f;
@ -494,7 +494,7 @@ double get_pitch()
return( FG_Theta );
}
double get_heading()
double get_heading( void )
{
struct fgFLIGHT *f;
@ -502,7 +502,7 @@ double get_heading()
return( FG_Psi*RAD_TO_DEG );
}
double get_altitude()
double get_altitude( void )
{
struct fgFLIGHT *f;
double rough_elev;
@ -551,7 +551,6 @@ Hptr fgHUDInit( struct fgAIRCRAFT current_aircraft, int color )
Hptr fgHUDAddHorizon( Hptr hud, int x_pos, int y_pos, int length, \
int hole_len, double (*load_value)() )
{
#ifndef WIN32
struct HUD_horizon *horizon;
struct HUD_instr *instrument;
HIptr tmp_first, tmp_next;
@ -571,7 +570,7 @@ Hptr fgHUDAddHorizon( Hptr hud, int x_pos, int y_pos, int length, \
return( NULL );
instrument->type = ARTIFICIAL_HORIZON;
instrument->instr = *horizon;
instrument->instr.horizon = *horizon;
instrument->instr.horizon.x_pos = x_pos;
instrument->instr.horizon.y_pos = y_pos;
instrument->instr.horizon.scr_width = length;
@ -582,13 +581,11 @@ Hptr fgHUDAddHorizon( Hptr hud, int x_pos, int y_pos, int length, \
hud->instruments = instrument;
return( hud );
#endif
}
Hptr fgHUDAddScale( Hptr hud, int type, int scr_pos, int scr_min, int scr_max, int div_min, int div_max, \
int orientation, int with_min, int min_value, int width_units, double (*load_value)() )
{
#ifndef WIN32
struct HUD_scale *scale;
struct HUD_instr *instrument;
HIptr tmp_first, tmp_next;
@ -608,7 +605,7 @@ Hptr fgHUDAddScale( Hptr hud, int type, int scr_pos, int scr_min, int scr_max, i
return( NULL );
instrument->type = SCALE;
instrument->instr = *scale;
instrument->instr.scale = *scale;
instrument->instr.scale.type = type;
instrument->instr.scale.scr_pos = scr_pos;
instrument->instr.scale.scr_min = scr_min;
@ -625,13 +622,11 @@ Hptr fgHUDAddScale( Hptr hud, int type, int scr_pos, int scr_min, int scr_max, i
hud->instruments = instrument;
return( hud );
#endif
}
Hptr fgHUDAddLabel( Hptr hud, int x_pos, int y_pos, int size, int blink, int justify, \
char *pre_str, char *post_str, char *format, double (*load_value)() )
{
#ifndef WIN32
struct HUD_label *label;
struct HUD_instr *instrument;
HIptr tmp_first, tmp_next;
@ -651,7 +646,7 @@ Hptr fgHUDAddLabel( Hptr hud, int x_pos, int y_pos, int size, int blink, int jus
return( NULL );
instrument->type = LABEL;
instrument->instr = *label;
instrument->instr.label = *label;
instrument->instr.label.x_pos = x_pos;
instrument->instr.label.y_pos = y_pos;
instrument->instr.label.size = size;
@ -666,14 +661,12 @@ Hptr fgHUDAddLabel( Hptr hud, int x_pos, int y_pos, int size, int blink, int jus
hud->instruments = instrument;
return( hud );
#endif
}
Hptr fgHUDAddLadder( Hptr hud, int x_pos, int y_pos, int scr_width, int scr_height, \
int hole_len, int div_units, int label_pos, int width_units, \
double (*load_roll)(), double (*load_pitch)() )
{
#ifndef WIN32
struct HUD_ladder *ladder;
struct HUD_instr *instrument;
HIptr tmp_first, tmp_next;
@ -693,7 +686,7 @@ Hptr fgHUDAddLadder( Hptr hud, int x_pos, int y_pos, int scr_width, int scr_heig
return( NULL );
instrument->type = LADDER;
instrument->instr = *ladder;
instrument->instr.ladder = *ladder;
instrument->instr.ladder.type = 0; // Not used.
instrument->instr.ladder.x_pos = x_pos;
instrument->instr.ladder.y_pos = y_pos;
@ -710,7 +703,6 @@ Hptr fgHUDAddLadder( Hptr hud, int x_pos, int y_pos, int scr_width, int scr_heig
hud->instruments = instrument;
return( hud );
#endif
}
/*
@ -807,10 +799,14 @@ void fgUpdateHUD( Hptr hud )
/* $Log$
/* Revision 1.6 1997/12/15 23:54:34 curt
/* Add xgl wrappers for debugging.
/* Generate terrain normals on the fly.
/* Revision 1.7 1998/01/19 18:40:20 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.6 1997/12/15 23:54:34 curt
* Add xgl wrappers for debugging.
* Generate terrain normals on the fly.
*
* Revision 1.5 1997/12/10 22:37:39 curt
* Prepended "fg" on the name of all global structures that didn't have it yet.
* i.e. "struct WEATHER {}" became "struct fgWEATHER {}"

View file

@ -109,7 +109,7 @@ struct HUD_scale {
int with_minimum;
int minimum_value;
int width_units;
double (*load_value)();
double (*load_value)( void );
};
struct HUD_circular_scale {
@ -122,7 +122,7 @@ struct HUD_circular_scale {
int orientation;
int label_position;
int width_units;
double (*load_value)();
double (*load_value)( void );
};
struct HUD_ladder {
@ -135,8 +135,8 @@ struct HUD_ladder {
int div_units;
int label_position;
int width_units;
double (*load_roll)();
double (*load_pitch)();
double (*load_roll)( void );
double (*load_pitch)( void );
};
struct HUD_circular_ladder {
@ -147,7 +147,7 @@ struct HUD_circular_ladder {
int orientation;
int label_position;
int width_units;
double (*load_value)();
double (*load_value)( void );
};
#define HORIZON_FIXED 1
@ -159,7 +159,7 @@ struct HUD_horizon {
int y_pos;
int scr_width;
int scr_hole;
double (*load_value)();
double (*load_value)( void );
};
#define LABEL_COUNTER 1
@ -175,7 +175,7 @@ struct HUD_label {
char *pre_str;
char *post_str;
char *format;
double (*load_value)();
double (*load_value)( void );
};
union HUD_instr_data {
@ -208,14 +208,14 @@ struct HUD {
typedef struct HUD *Hptr;
Hptr fgHUDInit( struct fgAIRCRAFT cur_aircraft, int color );
Hptr fgHUDAddHorizon( Hptr hud, int x_pos, int y_pos, int length, int hole_len, double (*load_value)() );
Hptr fgHUDAddHorizon( Hptr hud, int x_pos, int y_pos, int length, int hole_len, double (*load_value)( void ) );
Hptr fgHUDAddScale( Hptr hud, int type, int scr_pos, int scr_min, int scr_max, int div_min, int div_max, \
int orientation, int with_min, int min_value, int width_units, double (*load_value)() );
int orientation, int with_min, int min_value, int width_units, double (*load_value)( void ) );
Hptr fgHUDAddLabel( Hptr hud, int x_pos, int y_pos, int size, int blink, int justify, \
char *pre_str, char *post_str, char *format, double (*load_value)() );
char *pre_str, char *post_str, char *format, double (*load_value)( void ) );
Hptr fgHUDAddLadder( Hptr hud, int x_pos, int y_pos, int scr_width, int scr_height, \
int hole_len, int div_units, int label_pos, int max_value, \
double (*load_roll)(), double (*load_pitch)() );
double (*load_roll)( void ), double (*load_pitch)( void ) );
@ -225,7 +225,7 @@ struct HUD *fgHUDAddCircularLadder( Hptr hud, int scr_min, int scr_max, int div_
int max_value, double *(load_value) );
struct HUD *fgHUDAddNumDisp( Hptr hud, int x_pos, int y_pos, int size, int blink, \
char *pre_str, char *post_str, double *(load_value) ); */
void fgUpdateHUD();
void fgUpdateHUD( Hptr hud );
void fgUpdateHUD2( struct HUD *hud );
@ -233,9 +233,13 @@ void fgUpdateHUD2( struct HUD *hud );
/* $Log$
/* Revision 1.3 1997/12/30 16:36:41 curt
/* Merged in Durk's changes ...
/* Revision 1.4 1998/01/19 18:40:21 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.3 1997/12/30 16:36:41 curt
* Merged in Durk's changes ...
*
* Revision 1.2 1997/12/10 22:37:40 curt
* Prepended "fg" on the name of all global structures that didn't have it yet.
* i.e. "struct WEATHER {}" became "struct fgWEATHER {}"

View file

@ -28,7 +28,7 @@
#include "../Aircraft/aircraft.h"
void fgControlsInit() {
void fgControlsInit( void ) {
int i;
struct fgCONTROLS *c;
c = &current_aircraft.controls;
@ -167,10 +167,14 @@ void fgThrottleSet(int engine, double pos) {
/* $Log$
/* Revision 1.4 1997/12/10 22:37:41 curt
/* Prepended "fg" on the name of all global structures that didn't have it yet.
/* i.e. "struct WEATHER {}" became "struct fgWEATHER {}"
/* Revision 1.5 1998/01/19 18:40:22 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.4 1997/12/10 22:37:41 curt
* Prepended "fg" on the name of all global structures that didn't have it yet.
* i.e. "struct WEATHER {}" became "struct fgWEATHER {}"
*
* Revision 1.3 1997/08/27 03:30:01 curt
* Changed naming scheme of basic shared structures.
*

View file

@ -62,7 +62,7 @@ struct fgCONTROLS {
*/
void fgControlsInit();
void fgControlsInit( void );
void fgElevMove(double amt);
void fgElevSet(double pos);
@ -81,10 +81,14 @@ void fgThrottleSet(int engine, double pos);
/* $Log$
/* Revision 1.7 1997/12/15 23:54:36 curt
/* Add xgl wrappers for debugging.
/* Generate terrain normals on the fly.
/* Revision 1.8 1998/01/19 18:40:22 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.7 1997/12/15 23:54:36 curt
* Add xgl wrappers for debugging.
* Generate terrain normals on the fly.
*
* Revision 1.6 1997/12/10 22:37:41 curt
* Prepended "fg" on the name of all global structures that didn't have it yet.
* i.e. "struct WEATHER {}" became "struct fgWEATHER {}"

View file

@ -25,6 +25,7 @@
#include <stdio.h>
#include "flight.h"
#include "LaRCsim/ls_interface.h"
/* Initialize the flight model parameters */
@ -67,9 +68,13 @@ int fgFlightModelUpdate(int model, struct fgFLIGHT *f, int multiloop) {
/* $Log$
/* Revision 1.6 1998/01/19 18:35:43 curt
/* Minor tweaks and fixes for cygwin32.
/* Revision 1.7 1998/01/19 18:40:23 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.6 1998/01/19 18:35:43 curt
* Minor tweaks and fixes for cygwin32.
*
* Revision 1.5 1997/12/30 20:47:37 curt
* Integrated new event manager with subsystem initializations.
*

View file

@ -59,6 +59,9 @@
#include "ls_types.h"
#include "ls_constants.h"
#include "atmos_62.h"
#include <math.h>
#define alt_0 d_a_table[index ][0]
@ -211,7 +214,7 @@ void ls_atmos( SCALAR altitude, SCALAR * sigma, SCALAR * v_sound,
{ 240000., 1.08270E-07, 9.47120E+02, 0.00000E+00, 0.00000E+00 }
};
index = altitude / 2000;
index = (int)( altitude / 2000 );
if (index > (MAX_ALT_INDEX-2))
{
index = MAX_ALT_INDEX-2; /* limit maximum altitude */

View file

@ -33,6 +33,10 @@
$Header$
$Log$
Revision 1.2 1998/01/19 18:40:23 curt
Tons of little changes to clean up the code and to remove fatal errors
when building with the c++ compiler.
Revision 1.1 1997/05/29 00:09:53 curt
Initial Flight Gear revision.
@ -71,8 +75,12 @@ Initial Flight Gear revision.
--------------------------------------------------------------------------*/
void inertias() {}
void subsystems() {}
#include "ls_types.h"
#include "default_model_routines.h"
void inertias( SCALAR dt, int Initialize ) {}
void subsystems( SCALAR dt, int Initialize ) {}
/* void engine() {} */
/* void gear() {} */

View file

@ -1,25 +1,31 @@
LaRCsim.o: LaRCsim.c ls_types.h ls_constants.h ls_generic.h \
ls_sim_control.h ls_cockpit.h
atmos_62.o: atmos_62.c ls_types.h ls_constants.h
default_model_routines.o: default_model_routines.c
ls_accel.o: ls_accel.c ls_types.h ls_generic.h ls_constants.h
ls_aux.o: ls_aux.c ls_types.h ls_constants.h ls_generic.h
ls_geodesy.o: ls_geodesy.c ls_types.h ls_constants.h
ls_gravity.o: ls_gravity.c ls_types.h ls_constants.h
ls_init.o: ls_init.c ls_types.h ls_sym.h ls_generic.h
atmos_62.o: atmos_62.c ls_types.h ls_constants.h atmos_62.h
default_model_routines.o: default_model_routines.c ls_types.h \
default_model_routines.h
ls_accel.o: ls_accel.c ls_types.h ls_generic.h ls_constants.h \
ls_accel.h
ls_aux.o: ls_aux.c ls_types.h ls_constants.h ls_generic.h ls_aux.h \
atmos_62.h ls_geodesy.h ls_gravity.h
ls_geodesy.o: ls_geodesy.c ls_types.h ls_constants.h ls_geodesy.h
ls_gravity.o: ls_gravity.c ls_types.h ls_constants.h ls_gravity.h
ls_init.o: ls_init.c ls_types.h ls_sym.h ls_step.h ls_init.h \
navion_init.h ls_generic.h
ls_interface.o: ls_interface.c ls_types.h ls_constants.h ls_generic.h \
ls_sim_control.h ls_cockpit.h ls_interface.h ../flight.h \
../Slew/slew.h ../LaRCsim/ls_interface.h ../../Aircraft/aircraft.h \
../Slew/slew.h ../LaRCsim/ls_interface.h ls_step.h ls_accel.h \
ls_aux.h ls_model.h ls_init.h ../../Aircraft/aircraft.h \
../../Aircraft/../Flight/flight.h \
../../Aircraft/../Controls/controls.h \
../../Aircraft/../Controls/../Include/limits.h
ls_model.o: ls_model.c ls_types.h
ls_step.o: ls_step.c ls_types.h ls_constants.h ls_generic.h
ls_model.o: ls_model.c ls_types.h ls_model.h default_model_routines.h
ls_step.o: ls_step.c ls_types.h ls_constants.h ls_generic.h ls_accel.h \
ls_aux.h ls_model.h ls_step.h ls_geodesy.h ls_gravity.h
ls_sync.o: ls_sync.c ls_types.h ls_sim_control.h
mymain.o: mymain.c ls_types.h ls_cockpit.h ls_generic.h
navion_aero.o: navion_aero.c ls_types.h ls_generic.h ls_cockpit.h
navion_engine.o: navion_engine.c ls_types.h ls_constants.h \
ls_generic.h ls_cockpit.h ls_sim_control.h
ls_generic.h ls_sim_control.h ls_cockpit.h
navion_gear.o: navion_gear.c ls_types.h ls_constants.h ls_generic.h \
ls_cockpit.h
navion_init.o: navion_init.c ls_types.h ls_generic.h ls_cockpit.h

View file

@ -38,6 +38,10 @@
$Header$
$Log$
Revision 1.2 1998/01/19 18:40:24 curt
Tons of little changes to clean up the code and to remove fatal errors
when building with the c++ compiler.
Revision 1.1 1997/05/29 00:09:53 curt
Initial Flight Gear revision.
@ -87,10 +91,10 @@ Initial Flight Gear revision.
#include "ls_types.h"
#include "ls_generic.h"
#include "ls_constants.h"
#include "ls_accel.h"
#include <math.h>
void ls_accel( )
{
void ls_accel( void ) {
SCALAR inv_Mass, inv_Radius;
SCALAR ixz2, c0, c1, c2, c3, c4, c5, c6, c7, c8, c9, c10;

View file

@ -47,6 +47,10 @@
$Header$
$Log$
Revision 1.2 1998/01/19 18:40:24 curt
Tons of little changes to clean up the code and to remove fatal errors
when building with the c++ compiler.
Revision 1.1 1997/05/29 00:09:54 curt
Initial Flight Gear revision.
@ -115,15 +119,22 @@ Initial Flight Gear revision.
#include "ls_types.h"
#include "ls_constants.h"
#include "ls_generic.h"
#include "ls_aux.h"
#include "atmos_62.h"
#include "ls_geodesy.h"
#include "ls_gravity.h"
#include <math.h>
void ls_aux()
{
void ls_aux( void ) {
SCALAR dx_pilot_from_cg, dy_pilot_from_cg, dz_pilot_from_cg;
SCALAR inv_Mass;
/* SCALAR inv_Mass; */
SCALAR v_XZ_plane_2, signU, v_tangential;
SCALAR inv_radius_ratio;
/* SCALAR inv_radius_ratio; */
SCALAR cos_rwy_hdg, sin_rwy_hdg;
SCALAR mach2, temp_ratio, pres_ratio;

View file

@ -40,6 +40,10 @@
$Header$
$Log$
Revision 1.2 1998/01/19 18:40:25 curt
Tons of little changes to clean up the code and to remove fatal errors
when building with the c++ compiler.
Revision 1.1 1997/05/29 00:09:56 curt
Initial Flight Gear revision.
@ -90,6 +94,7 @@ Initial Flight Gear revision.
#include "ls_types.h"
#include "ls_constants.h"
#include "ls_geodesy.h"
#include <math.h>
/* ONE_SECOND is pi/180/60/60, or about 100 feet at earths' equator */
@ -97,12 +102,8 @@ Initial Flight Gear revision.
#define HALF_PI 0.5*PI
void ls_geoc_to_geod( lat_geoc, radius, lat_geod, alt, sea_level_r )
SCALAR lat_geoc;
SCALAR radius;
SCALAR *lat_geod;
SCALAR *alt;
SCALAR *sea_level_r;
void ls_geoc_to_geod( SCALAR lat_geoc, SCALAR radius, SCALAR *lat_geod,
SCALAR *alt, SCALAR *sea_level_r )
{
SCALAR t_lat, x_alpha, mu_alpha, delt_mu, r_alpha, l_point, rho_alpha;
SCALAR sin_mu_a, denom,delt_lambda, lambda_sl, sin_lambda_sl;
@ -137,11 +138,9 @@ void ls_geoc_to_geod( lat_geoc, radius, lat_geod, alt, sea_level_r )
}
}
void ls_geod_to_geoc( lat_geod, alt, sl_radius, lat_geoc )
SCALAR lat_geod;
SCALAR alt;
SCALAR *sl_radius;
SCALAR *lat_geoc;
void ls_geod_to_geoc( SCALAR lat_geod, SCALAR alt,
SCALAR *sl_radius, SCALAR *lat_geoc )
{
SCALAR lambda_sl, sin_lambda_sl, cos_lambda_sl, sin_mu, cos_mu, px, py;

View file

@ -35,6 +35,10 @@
$Header$
$Log$
Revision 1.2 1998/01/19 18:40:26 curt
Tons of little changes to clean up the code and to remove fatal errors
when building with the c++ compiler.
Revision 1.1 1997/05/29 00:09:56 curt
Initial Flight Gear revision.
@ -71,6 +75,7 @@ Initial Flight Gear revision.
--------------------------------------------------------------------------*/
#include "ls_types.h"
#include "ls_constants.h"
#include "ls_gravity.h"
#include <math.h>
#define GM 1.4076431E16

View file

@ -34,6 +34,10 @@
$Header$
$Log$
Revision 1.4 1998/01/19 18:40:26 curt
Tons of little changes to clean up the code and to remove fatal errors
when building with the c++ compiler.
Revision 1.3 1998/01/05 22:19:25 curt
#ifdef'd out some unused code that was problematic for MSVC++ to compile.
@ -90,6 +94,9 @@ static char rcsid[] = "$Id$";
#include <stdio.h>
#include "ls_types.h"
#include "ls_sym.h"
#include "ls_step.h"
#include "ls_init.h"
#include "navion_init.h"
/* temp */
#include "ls_generic.h"
@ -117,16 +124,16 @@ typedef struct
extern SCALAR Simtime;
static int Symbols_loaded = 0;
/* static int Symbols_loaded = 0; */
static int Number_of_Continuous_States = 0;
static int Number_of_Discrete_States = 0;
static cont_state_rec Continuous_States[ MAX_NUMBER_OF_CONTINUOUS_STATES ];
static disc_state_rec Discrete_States[ MAX_NUMBER_OF_DISCRETE_STATES ];
void ls_init_init()
{
int i, error;
void ls_init_init( void ) {
int i;
/* int error; */
if (Number_of_Continuous_States == 0)
{
@ -178,9 +185,8 @@ void ls_init_init()
*/
}
void ls_init()
{
int i;
void ls_init( void ) {
/* int i; */
Simtime = 0;
@ -346,11 +352,10 @@ void ls_init_put_set( FILE *fp )
return;
}
void ls_save_current_as_ic()
{
void ls_save_current_as_ic( void ) {
/* Save current states as initial conditions */
int i, error;
/* int i, error; */
/* commented out by CLO
for(i=0;i<Number_of_Continuous_States;i++)

View file

@ -235,6 +235,11 @@ $Original log: LaRCsim.c,v $
#include "ls_sim_control.h"
#include "ls_cockpit.h"
#include "ls_interface.h"
#include "ls_step.h"
#include "ls_accel.h"
#include "ls_aux.h"
#include "ls_model.h"
#include "ls_init.h"
#include "../flight.h"
#include "../../Aircraft/aircraft.h"
@ -271,8 +276,7 @@ static char matname[MAX_FILE_NAME_LENGTH] = "run.m";
void ls_stamp()
{
void ls_stamp( void ) {
char rcsid[] = "$Id$";
char revid[] = "$Revision$";
char dateid[] = "$Date$";
@ -297,8 +301,7 @@ void ls_stamp()
return;
}
void ls_setdefopts()
{
void ls_setdefopts( void ) {
/* set default values for most options */
sim_control_.debug = 0; /* change to non-zero if in dbx! */
@ -307,7 +310,6 @@ void ls_setdefopts()
sim_control_.write_mat = 0; /* write matrix-x/matlab script */
sim_control_.write_tab = 0; /* write tab delim. history file */
sim_control_.write_asc1 = 0; /* write GetData file */
sim_control_.sim_type = GLmouse; /* hook up to mouse */
sim_control_.save_spacing = DEFAULT_SAVE_SPACING;
/* interpolation on recording */
sim_control_.write_spacing = DEFAULT_WRITE_SPACING;
@ -315,8 +317,8 @@ void ls_setdefopts()
sim_control_.end_time = DEFAULT_END_TIME;
sim_control_.model_hz = DEFAULT_MODEL_HZ;
sim_control_.term_update_hz = DEFAULT_TERM_UPDATE_HZ;
sim_control_.time_slices = DEFAULT_END_TIME * DEFAULT_MODEL_HZ /
DEFAULT_SAVE_SPACING;
sim_control_.time_slices = (long int)(DEFAULT_END_TIME * DEFAULT_MODEL_HZ /
DEFAULT_SAVE_SPACING);
sim_control_.paused = 0;
speedup = 1.0;
@ -482,12 +484,7 @@ int ls_checkopts(argc, argv) /* check and set options flags */
#endif /* COMPILE_THIS_CODE_THIS_USELESS_CODE */
void ls_loop( dt, initialize )
SCALAR dt;
int initialize;
{
void ls_loop( SCALAR dt, int initialize ) {
/* printf (" In ls_loop()\n"); */
ls_step( dt, initialize );
/* if (sim_control_.sim_type == cockpit ) ls_ACES(); */
@ -498,7 +495,7 @@ int initialize;
int ls_cockpit() {
int ls_cockpit( void ) {
struct fgCONTROLS *c;
sim_control_.paused = 0;
@ -515,6 +512,7 @@ int ls_cockpit() {
printf("%.4f,%.4f,%.2f ", Latitude, Longitude, Altitude);
printf("%.2f,%.2f,%.2f\n", Phi, Theta, Psi); */
return( 0 );
}
@ -734,6 +732,8 @@ int fgFlight_2_LaRCsim (struct fgFLIGHT *f) {
X_pilot_rwy = FG_X_pilot_rwy;
Y_pilot_rwy = FG_Y_pilot_rwy;
H_pilot_rwy = FG_H_pilot_rwy;
return( 0 );
}
@ -908,11 +908,17 @@ int fgLaRCsim_2_Flight (struct fgFLIGHT *f) {
FG_X_pilot_rwy = X_pilot_rwy;
FG_Y_pilot_rwy = Y_pilot_rwy;
FG_H_pilot_rwy = H_pilot_rwy;
return ( 0 );
}
/* Flight Gear Modification Log
*
* $Log$
* Revision 1.13 1998/01/19 18:40:26 curt
* Tons of little changes to clean up the code and to remove fatal errors
* when building with the c++ compiler.
*
* Revision 1.12 1998/01/06 01:20:16 curt
* Tweaks to help building with MSVC++
*

View file

@ -37,14 +37,24 @@ int fgLaRCsimInit(double dt);
/* update position based on inputs, positions, velocities, etc. */
int fgLaRCsimUpdate(int multiloop);
/* Convert from the fgFLIGHT struct to the LaRCsim generic_ struct */
int fgFlight_2_LaRCsim (struct fgFLIGHT *f);
/* Convert from the LaRCsim generic_ struct to the fgFLIGHT struct */
int fgLaRCsim_2_Flight (struct fgFLIGHT *f);
#endif /* LS_INTERFACE_H */
/* $Log$
/* Revision 1.3 1997/07/23 21:52:20 curt
/* Put comments around the text after an #endif for increased portability.
/* Revision 1.4 1998/01/19 18:40:27 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.3 1997/07/23 21:52:20 curt
* Put comments around the text after an #endif for increased portability.
*
* Revision 1.2 1997/05/29 22:39:59 curt
* Working on incorporating the LaRCsim flight model.
*

View file

@ -37,6 +37,10 @@
CURRENT RCS HEADER INFO:
$Header$
$Log$
Revision 1.2 1998/01/19 18:40:27 curt
Tons of little changes to clean up the code and to remove fatal errors
when building with the c++ compiler.
Revision 1.1 1997/05/29 00:09:58 curt
Initial Flight Gear revision.
@ -74,13 +78,14 @@ Initial Flight Gear revision.
--------------------------------------------------------------------------*/
#include "ls_types.h"
#include "ls_model.h"
#include "default_model_routines.h"
void ls_model( SCALAR dt, int Initialize )
{
inertias( dt, Initialize );
subsystems( dt, Initialize );
aero( dt, Initialize );
engine( dt, Initialize );
gear( dt, Initialize );
void ls_model( SCALAR dt, int Initialize ) {
inertias( dt, Initialize );
subsystems( dt, Initialize );
aero( dt, Initialize );
engine( dt, Initialize );
gear( dt, Initialize );
}

View file

@ -50,6 +50,10 @@
$Header$
$Log$
Revision 1.2 1998/01/19 18:40:28 curt
Tons of little changes to clean up the code and to remove fatal errors
when building with the c++ compiler.
Revision 1.1 1997/05/29 00:09:59 curt
Initial Flight Gear revision.
@ -105,17 +109,18 @@ Initial Flight Gear revision.
#include "ls_types.h"
#include "ls_constants.h"
#include "ls_generic.h"
#include "ls_accel.h"
#include "ls_aux.h"
#include "ls_model.h"
#include "ls_step.h"
#include "ls_geodesy.h"
#include "ls_gravity.h"
/* #include "ls_sim_control.h" */
#include <math.h>
extern SCALAR Simtime; /* defined in ls_main.c */
void ls_step( dt, Initialize )
SCALAR dt;
int Initialize;
{
void ls_step( SCALAR dt, int Initialize ) {
static int inited = 0;
SCALAR dth;
static SCALAR v_dot_north_past, v_dot_east_past, v_dot_down_past;
@ -178,7 +183,7 @@ int Initialize;
/* Initialize vehicle model */
ls_aux();
ls_model();
ls_model(0.0, 0);
/* Calculate initial accelerations */

View file

@ -8,6 +8,6 @@
COCKPIT cockpit_;
GENERIC generic_;
int main() {
int main(int argc, char **argv) {
model_init();
}

View file

@ -112,8 +112,7 @@ ring is given below:
extern COCKPIT cockpit_;
void aero()
{
void aero( SCALAR dt, int Initialize ) {
static int init = 0;
SCALAR u, w;
@ -123,7 +122,7 @@ void aero()
static SCALAR yaw_scale = -0.1;
static SCALAR scale = 1.0;
static SCALAR trim_inc = 0.0002;
/* static SCALAR trim_inc = 0.0002; */
/* static SCALAR long_trim; */
static DATA U_0;

View file

@ -61,15 +61,15 @@ $Header$
#include "ls_types.h"
#include "ls_constants.h"
#include "ls_generic.h"
#include "ls_cockpit.h"
#include "ls_sim_control.h"
#include "ls_cockpit.h"
extern SIM_CONTROL sim_control_;
void engine( SCALAR dt, int init )
{
if (init || sim_control_.sim_type != cockpit)
Throttle[3] = Throttle_pct;
void engine( SCALAR dt, int init ) {
/* if (init) { */
Throttle[3] = Throttle_pct;
/* } */
/* F_X_engine = Throttle[3]*813.4/0.2; */ /* original code */
/* F_Z_engine = Throttle[3]*11.36/0.2; */ /* original code */

View file

@ -36,6 +36,10 @@
$Header$
$Log$
Revision 1.2 1998/01/19 18:40:29 curt
Tons of little changes to clean up the code and to remove fatal errors
when building with the c++ compiler.
Revision 1.1 1997/05/29 00:10:02 curt
Initial Flight Gear revision.
@ -108,8 +112,7 @@ clear3( DATA v[] )
v[0] = 0.; v[1] = 0.; v[2] = 0.;
}
gear()
{
void gear( SCALAR dt, int Initialize ) {
char rcsid[] = "$Id$";
/*

View file

@ -60,8 +60,7 @@
#include "ls_generic.h"
#include "ls_cockpit.h"
void model_init()
{
void model_init( void ) {
Throttle[3] = 0.2; Rudder_pedal = 0; Lat_control = 0; Long_control = 0;

View file

@ -70,7 +70,7 @@ static GLint winWidth, winHeight;
/* pointer to scenery structure */
/* static GLint scenery, runway; */
double Simtime;
/* double Simtime; */
/* Another hack */
int use_signals = 0;
@ -86,7 +86,7 @@ int displayInstruments;
* fgInitVisuals() -- Initialize various GL/view parameters
**************************************************************************/
static void fgInitVisuals() {
static void fgInitVisuals( void ) {
struct fgLIGHT *l;
struct fgTIME *t;
struct fgWEATHER *w;
@ -121,7 +121,7 @@ static void fgInitVisuals() {
* Update the view volume, position, and orientation
**************************************************************************/
static void fgUpdateViewParams() {
static void fgUpdateViewParams( void ) {
struct fgFLIGHT *f;
struct fgLIGHT *l;
struct fgTIME *t;
@ -183,7 +183,7 @@ static void fgUpdateViewParams() {
/*************************************************************************
* Draw a basic instrument panel
************************************************************************/
static void fgUpdateInstrViewParams() {
static void fgUpdateInstrViewParams( void ) {
xglViewport(0, 0 , (GLint)winWidth, (GLint)winHeight / 2);
xglMatrixMode(GL_PROJECTION);
@ -357,7 +357,7 @@ void fgUpdateTimeDepCalcs(int multi_loop) {
}
void fgInitTimeDepCalcs() {
void fgInitTimeDepCalcs( void ) {
/* initialize timer */
#ifdef USE_ITIMER
@ -517,7 +517,7 @@ static void fgMainLoop( void ) {
FG_Altitude * FEET_TO_METER);
}
/* fgAircraftOutputCurrent(a); */
fgAircraftOutputCurrent(a);
/* see if we need to load any new scenery tiles */
/* fgTileMgrUpdate(); */
@ -636,9 +636,13 @@ int main( int argc, char *argv[] ) {
/* $Log$
/* Revision 1.48 1998/01/19 18:35:46 curt
/* Minor tweaks and fixes for cygwin32.
/* Revision 1.49 1998/01/19 18:40:31 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.48 1998/01/19 18:35:46 curt
* Minor tweaks and fixes for cygwin32.
*
* Revision 1.47 1998/01/13 00:23:08 curt
* Initial changes to support loading and management of scenery tiles. Note,
* there's still a fair amount of work left to be done.

View file

@ -20,8 +20,8 @@ GLUTmain.o: GLUTmain.c ../XGL/xgl.h GLUTkey.h fg_init.h views.h \
../Cockpit/../Controls/controls.h ../Joystick/joystick.h \
../Math/fg_geodesy.h ../Math/polar.h ../Math/../Include/types.h \
../Scenery/mesh.h ../Scenery/scenery.h ../Scenery/../Include/types.h \
../Time/event.h ../Time/fg_timer.h ../Time/sunpos.h \
../Weather/weather.h
../Scenery/tilemgr.h ../Time/event.h ../Time/fg_timer.h \
../Time/sunpos.h ../Weather/weather.h
fg_init.o: fg_init.c fg_init.h views.h ../Include/types.h \
../Flight/flight.h ../Flight/Slew/slew.h \
../Flight/LaRCsim/ls_interface.h ../Flight/LaRCsim/../flight.h \
@ -34,10 +34,9 @@ fg_init.o: fg_init.c fg_init.h views.h ../Include/types.h \
../Astro/stars.h ../Astro/sun.h ../Cockpit/cockpit.h ../Cockpit/hud.h \
../Cockpit/../Aircraft/aircraft.h ../Cockpit/../Flight/flight.h \
../Cockpit/../Controls/controls.h ../Joystick/joystick.h \
../Math/fg_random.h ../Scenery/tilemgr.h ../Scenery/mesh.h \
../Scenery/scenery.h ../Scenery/../Include/types.h ../Time/event.h \
../Math/fg_random.h ../Scenery/mesh.h ../Scenery/scenery.h \
../Scenery/../Include/types.h ../Scenery/tilemgr.h ../Time/event.h \
../Time/sunpos.h ../Weather/weather.h
probdemo.o: probdemo.c ../XGL/xgl.h
views.o: views.c views.h ../Include/types.h ../Flight/flight.h \
../Flight/Slew/slew.h ../Flight/LaRCsim/ls_interface.h \
../Flight/LaRCsim/../flight.h ../Math/mat3.h ../Time/fg_time.h \

View file

@ -110,11 +110,23 @@ void fgInitSubsystems( void ) {
FG_Runway_altitude = 3234.5;
FG_Runway_heading = 102.0 * DEG_TO_RAD;
/* Initial Position at GLOBE airport */
/* Initial Position at (P13) GLOBE airport */
FG_Longitude = ( -398391.28 / 3600.0 ) * DEG_TO_RAD;
FG_Latitude = ( 120070.41 / 3600.0 ) * DEG_TO_RAD;
FG_Altitude = FG_Runway_altitude + 3.758099;
/* Initial Position at (SEZ) SEDONA airport */
FG_Longitude = -111.7884614 * DEG_TO_RAD;
FG_Latitude = 34.8486289 * DEG_TO_RAD;
FG_Runway_altitude = 4827;
FG_Altitude = FG_Runway_altitude + 3.758099;
/* Initial Position at (ANE) Anoka County airport */
FG_Longitude = -93.2113889 * DEG_TO_RAD;
FG_Latitude = 45.145 * DEG_TO_RAD;
FG_Runway_altitude = 912;
FG_Altitude = FG_Runway_altitude + 3.758099;
/* Initial Position north of the city of Globe */
/* FG_Longitude = ( -398673.28 / 3600.0 ) * DEG_TO_RAD; */
/* FG_Latitude = ( 120625.64 / 3600.0 ) * DEG_TO_RAD; */
@ -137,10 +149,8 @@ void fgInitSubsystems( void ) {
/* FG_Longitude = ( 88128.00 / 3600.0 ) * DEG_TO_RAD; */
/* FG_Latitude = ( 93312.00 / 3600.0 ) * DEG_TO_RAD; */
FG_Runway_altitude = 4000.0;
FG_Altitude = FG_Runway_altitude + 3.758099;
printf("Initial position is: (%.4f, %.4f, %.2f)\n",
printf("Initial position is: (%.4f, %.4f, %.2f)\n",
FG_Longitude * RAD_TO_DEG, FG_Latitude * RAD_TO_DEG,
FG_Altitude * FEET_TO_METER);
@ -277,10 +287,14 @@ void fgInitSubsystems( void ) {
/* $Log$
/* Revision 1.30 1998/01/13 00:23:09 curt
/* Initial changes to support loading and management of scenery tiles. Note,
/* there's still a fair amount of work left to be done.
/* Revision 1.31 1998/01/19 18:40:32 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.30 1998/01/13 00:23:09 curt
* Initial changes to support loading and management of scenery tiles. Note,
* there's still a fair amount of work left to be done.
*
* Revision 1.29 1998/01/08 02:22:08 curt
* Beginning to integrate Tile management subsystem.
*

View file

@ -3,14 +3,16 @@ geometry.o: geometry.c geometry.h mesh.h
mesh.o: mesh.c ../Include/constants.h ../Include/types.h \
../Math/fg_geodesy.h ../Math/fg_random.h ../Math/mat3.h \
../Math/polar.h ../Math/../Include/types.h mesh.h common.h scenery.h
obj.o: obj.c ../XGL/xgl.h obj.h scenery.h ../Include/types.h \
obj.o: obj.c ../XGL/xgl.h obj.h ../Include/types.h scenery.h \
../Math/mat3.h
scenery.o: scenery.c ../XGL/xgl.h ../Include/general.h obj.h scenery.h \
../Include/types.h
tilemgr.o: tilemgr.c ../XGL/xgl.h tileutils.h ../Aircraft/aircraft.h \
scenery.o: scenery.c ../XGL/xgl.h ../Include/general.h obj.h \
../Include/types.h scenery.h
tilemgr.o: tilemgr.c ../XGL/xgl.h scenery.h ../Include/types.h \
tileutils.h obj.h ../Aircraft/aircraft.h \
../Aircraft/../Flight/flight.h ../Aircraft/../Flight/Slew/slew.h \
../Aircraft/../Flight/LaRCsim/ls_interface.h \
../Aircraft/../Flight/LaRCsim/../flight.h \
../Aircraft/../Controls/controls.h \
../Aircraft/../Controls/../Include/limits.h
../Aircraft/../Controls/../Include/limits.h ../Include/constants.h \
../Include/general.h
tileutils.o: tileutils.c tileutils.h ../Include/constants.h

View file

@ -95,7 +95,7 @@ void vrmlGeomOptionsValue(char *value) {
/* We've finished parsing the current geometry. Now do whatever needs
* to be done with it (like generating the OpenGL call list for
* instance */
void vrmlHandleGeometry() {
void vrmlHandleGeometry( void ) {
switch(vrmlGeometryType) {
case VRML_ELEV_GRID:
mesh_do_it(&eg);
@ -104,7 +104,7 @@ void vrmlHandleGeometry() {
/* Finish up the current vrml geometry statement */
int vrmlFreeGeometry() {
int vrmlFreeGeometry( void ) {
printf("Freeing geometry type = %d\n", vrmlGeometryType);
switch(vrmlGeometryType) {
@ -120,9 +120,13 @@ int vrmlFreeGeometry() {
/* $Log$
/* Revision 1.5 1998/01/06 01:20:23 curt
/* Tweaks to help building with MSVC++
/* Revision 1.6 1998/01/19 18:40:35 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.5 1998/01/06 01:20:23 curt
* Tweaks to help building with MSVC++
*
* Revision 1.4 1997/08/27 03:30:26 curt
* Changed naming scheme of basic shared structures.
*

View file

@ -46,19 +46,23 @@ void vrmlGeomOptionsValue(char *value);
/* We've finished parsing the current geometry. Now do whatever needs
* to be done with it (like generating the OpenGL call list for
* instance */
void vrmlHandleGeometry();
void vrmlHandleGeometry( void );
/* Finish up the current vrml geometry statement */
int vrmlFreeGeometry();
int vrmlFreeGeometry( void );
#endif /* GEOMETRY_H */
/* $Log$
/* Revision 1.2 1997/07/23 21:52:25 curt
/* Put comments around the text after an #endif for increased portability.
/* Revision 1.3 1998/01/19 18:40:36 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.2 1997/07/23 21:52:25 curt
* Put comments around the text after an #endif for increased portability.
*
* Revision 1.1 1997/06/29 21:16:48 curt
* More twiddling with the Scenery Management system.
*

View file

@ -72,7 +72,7 @@ void mesh_init(struct MESH *m) {
/* return a pointer to a new mesh structure (no data array allocated yet) */
struct MESH *(new_mesh)() {
struct MESH *(new_mesh)( void ) {
struct MESH *mesh_ptr;
mesh_ptr = (struct MESH *)malloc(sizeof(struct MESH));
@ -396,9 +396,13 @@ GLint mesh_to_OpenGL(struct MESH *m) {
/* $Log$
/* Revision 1.25 1998/01/07 03:31:27 curt
/* Miscellaneous tweaks.
/* Revision 1.26 1998/01/19 18:40:36 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.25 1998/01/07 03:31:27 curt
* Miscellaneous tweaks.
*
* Revision 1.24 1997/12/15 23:54:59 curt
* Add xgl wrappers for debugging.
* Generate terrain normals on the fly.

View file

@ -52,7 +52,7 @@ struct MESH {
/* return a pointer to a new mesh structure (no data array allocated yet) */
struct MESH *(new_mesh)();
struct MESH *(new_mesh)( void );
/* initialize the non-array mesh values */
void mesh_init(struct MESH *m);
@ -82,9 +82,13 @@ GLint mesh_to_OpenGL(struct MESH *m);
/* $Log$
/* Revision 1.7 1997/08/27 03:30:29 curt
/* Changed naming scheme of basic shared structures.
/* Revision 1.8 1998/01/19 18:40:37 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.7 1997/08/27 03:30:29 curt
* Changed naming scheme of basic shared structures.
*
* Revision 1.6 1997/08/02 19:10:15 curt
* Incorporated mesh2GL.c into mesh.c
*

View file

@ -49,7 +49,7 @@ struct fgSCENERY scenery;
/* Initialize the Scenery Management system */
void fgSceneryInit() {
void fgSceneryInit( void ) {
printf("Initializing scenery subsystem\n");
/* set the default terrain detail level */
@ -81,7 +81,7 @@ void fgSceneryUpdate(double lon, double lat, double elev) {
/* Render out the current scene */
void fgSceneryRender() {
void fgSceneryRender( void ) {
static GLfloat terrain_color[4] = { 0.6, 0.8, 0.4, 1.0 };
static GLfloat terrain_ambient[4];
static GLfloat terrain_diffuse[4];
@ -100,10 +100,14 @@ void fgSceneryRender() {
/* $Log$
/* Revision 1.31 1998/01/13 00:23:11 curt
/* Initial changes to support loading and management of scenery tiles. Note,
/* there's still a fair amount of work left to be done.
/* Revision 1.32 1998/01/19 18:40:37 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.31 1998/01/13 00:23:11 curt
* Initial changes to support loading and management of scenery tiles. Note,
* there's still a fair amount of work left to be done.
*
* Revision 1.30 1998/01/07 03:22:29 curt
* Moved astro stuff to .../Src/Astro/
*

View file

@ -47,7 +47,7 @@ extern struct fgSCENERY scenery;
/* Initialize the Scenery Management system */
void fgSceneryInit();
void fgSceneryInit( void );
/* Tell the scenery manager where we are so it can load the proper data, and
@ -56,17 +56,21 @@ void fgSceneryUpdate(double lon, double lat, double elev);
/* Render out the current scene */
void fgSceneryRender();
void fgSceneryRender( void );
#endif /* SCENERY_H */
/* $Log$
/* Revision 1.12 1997/12/15 23:55:03 curt
/* Add xgl wrappers for debugging.
/* Generate terrain normals on the fly.
/* Revision 1.13 1998/01/19 18:40:38 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.12 1997/12/15 23:55:03 curt
* Add xgl wrappers for debugging.
* Generate terrain normals on the fly.
*
* Revision 1.11 1997/12/10 22:37:52 curt
* Prepended "fg" on the name of all global structures that didn't have it yet.
* i.e. "struct WEATHER {}" became "struct fgWEATHER {}"

View file

@ -48,7 +48,7 @@ struct fgCartesianPoint local_refs[49];
/* Initialize the Tile Manager subsystem */
void fgTileMgrInit() {
void fgTileMgrInit( void ) {
printf("Initializing Tile Manager subsystem.\n");
/* fgTileCacheInit(); */
}
@ -56,10 +56,11 @@ void fgTileMgrInit() {
/* given the current lon/lat, fill in the array of local chunks. If
* the chunk isn't already in the cache, then read it from disk. */
void fgTileMgrUpdate() {
void fgTileMgrUpdate( void ) {
struct fgFLIGHT *f;
struct fgGENERAL *g;
struct bucket p;
struct bucket p_last = {-1000, 0, 0, 0};
char base_path[256];
char file_name[256];
int i, j;
@ -70,6 +71,11 @@ void fgTileMgrUpdate() {
find_bucket(FG_Longitude * RAD_TO_DEG, FG_Latitude * RAD_TO_DEG, &p);
printf("Updating Tile list for %d,%d %d,%d\n", p.lon, p.lat, p.x, p.y);
if ( (p.lon == p_last.lon) && (p.lat == p_last.lat) &&
(p.x == p_last.x) && (p.y == p_last.y) ) {
/* same bucket as last time */
}
gen_idx_array(&p, local_tiles, 7, 7);
/* scenery.center = ref; */
@ -92,7 +98,7 @@ void fgTileMgrUpdate() {
/* Render the local tiles --- hack, hack, hack */
void fgTileMgrRender() {
void fgTileMgrRender( void ) {
static GLfloat terrain_color[4] = { 0.6, 0.8, 0.4, 1.0 };
static GLfloat terrain_ambient[4];
static GLfloat terrain_diffuse[4];
@ -118,10 +124,14 @@ void fgTileMgrRender() {
/* $Log$
/* Revision 1.3 1998/01/13 00:23:11 curt
/* Initial changes to support loading and management of scenery tiles. Note,
/* there's still a fair amount of work left to be done.
/* Revision 1.4 1998/01/19 18:40:38 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.3 1998/01/13 00:23:11 curt
* Initial changes to support loading and management of scenery tiles. Note,
* there's still a fair amount of work left to be done.
*
* Revision 1.2 1998/01/08 02:22:27 curt
* Continue working on basic features.
*

View file

@ -25,23 +25,27 @@
/* Initialize the Tile Manager subsystem */
void fgTileMgrInit();
void fgTileMgrInit( void );
/* given the current lon/lat, fill in the array of local chunks. If
* the chunk isn't already in the cache, then read it from disk. */
void fgTileMgrUpdate();
void fgTileMgrUpdate( void );
/* Render the local tiles --- hack, hack, hack */
void fgTileMgrRender();
void fgTileMgrRender( void );
/* $Log$
/* Revision 1.2 1998/01/13 00:23:11 curt
/* Initial changes to support loading and management of scenery tiles. Note,
/* there's still a fair amount of work left to be done.
/* Revision 1.3 1998/01/19 18:40:38 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.2 1998/01/13 00:23:11 curt
* Initial changes to support loading and management of scenery tiles. Note,
* there's still a fair amount of work left to be done.
*
* Revision 1.1 1998/01/07 23:50:51 curt
* "area" renamed to "tile"
*

View file

@ -41,11 +41,19 @@
1/16/98 - Release verison 0.23
1/17/98 - Change all "type function();" to "type function( void );"
--------------------------------------------------------------------------
| Todo
--------------------------------------------------------------------------
1/17/98 - Compile with c++
1/17/98 - in all .h's change #ifdef FILE_H -> #ifdef _FILE_H
1/17/98 - Remove some of the unused files such as ls_sync.c
12/29/97 - Scenery area manager
12/29/97 - View frustum culling

View file

@ -38,7 +38,7 @@ FG_VERSION = $(FG_VERSION_MAJOR).$(FG_VERSION_MINOR)
# Choose your weapons
#---------------------------------------------------------------------------
CC = gcc
CC = g++
FLEX = flex -f -L
BISON = bison -v --no-lines
AR = ar
@ -159,6 +159,10 @@ FG_CFLAGS = $(GLOBAL_CFLAGS) $(FG_DEBUG_FLAGS)
#---------------------------------------------------------------------------
# $Log$
# Revision 1.33 1998/01/19 18:40:15 curt
# Tons of little changes to clean up the code and to remove fatal errors
# when building with the c++ compiler.
#
# Revision 1.32 1998/01/19 18:35:40 curt
# Minor tweaks and fixes for cygwin32.
#

View file

@ -44,11 +44,12 @@
/* reset flight params to a specific position */
void fgSlewInit(double pos_x, double pos_y, double pos_z, double heading) {
struct FLIGHT *f;
struct fgFLIGHT *f;
f = &current_aircraft.flight;
/* f->pos_x = pos_x;
/*
f->pos_x = pos_x;
f->pos_y = pos_y;
f->pos_z = pos_z;
@ -64,14 +65,15 @@ void fgSlewInit(double pos_x, double pos_y, double pos_z, double heading) {
f->vel_Theta = 0.0;
f->vel_Psi = 0.0;
f->Psi = heading; */
f->Psi = heading;
*/
}
/* update position based on inputs, positions, velocities, etc. */
void fgSlewUpdate() {
struct FLIGHT *f;
struct CONTROLS *c;
void fgSlewUpdate( void ) {
struct fgFLIGHT *f;
struct fgCONTROLS *c;
f = &current_aircraft.flight;
c = &current_aircraft.controls;
@ -91,10 +93,14 @@ void fgSlewUpdate() {
/* $Log$
/* Revision 1.7 1997/12/15 23:54:42 curt
/* Add xgl wrappers for debugging.
/* Generate terrain normals on the fly.
/* Revision 1.8 1998/01/19 18:40:30 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.7 1997/12/15 23:54:42 curt
* Add xgl wrappers for debugging.
* Generate terrain normals on the fly.
*
* Revision 1.6 1997/08/27 03:30:11 curt
* Changed naming scheme of basic shared structures.
*

View file

@ -32,16 +32,20 @@
void fgSlewInit(double pos_x, double pos_y, double pos_z, double heading);
/* update position based on inputs, positions, velocities, etc. */
void fgSlewUpdate();
void fgSlewUpdate( void );
#endif /* SLEW_H */
/* $Log$
/* Revision 1.2 1997/07/23 21:52:20 curt
/* Put comments around the text after an #endif for increased portability.
/* Revision 1.3 1998/01/19 18:40:30 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.2 1997/07/23 21:52:20 curt
* Put comments around the text after an #endif for increased portability.
*
* Revision 1.1 1997/05/29 02:29:43 curt
* Moved to their own directory.
*

View file

@ -4,8 +4,7 @@ fg_time.o: fg_time.c fg_time.h ../Include/types.h ../Flight/flight.h \
../Flight/LaRCsim/../flight.h ../Include/constants.h \
../Time/fg_time.h
fg_timer.o: fg_timer.c fg_timer.h
scheduler.o: scheduler.c
sidereal.o: sidereal.c ../Include/constants.h
sptest.o: sptest.c sunpos.h ../Include/types.h ../Include/constants.h
sunpos.o: sunpos.c sunpos.h ../Include/types.h fg_time.h \
../Flight/flight.h ../Flight/Slew/slew.h \
../Flight/LaRCsim/ls_interface.h ../Flight/LaRCsim/../flight.h \

View file

@ -45,7 +45,7 @@
struct fgEVENT {
char description[256];
void (*event)(); /* pointer to function */
void (*event)( void ); /* pointer to function */
int status; /* status flag */
long interval; /* interval in ms between each iteration of this event */
@ -80,13 +80,13 @@ int queue_end;
/* initialize the run queue */
void initq() {
void initq( void ) {
queue_front = queue_end = 0;
}
/* return queue empty status */
int emptyq() {
int emptyq( void ) {
if ( queue_front == queue_end ) {
return(1);
} else {
@ -96,7 +96,7 @@ int emptyq() {
/* return queue full status */
int fullq() {
int fullq( void ) {
if ( (queue_end + 1) % MAX_RUN_QUEUE == queue_front ) {
return(1);
} else {
@ -121,7 +121,7 @@ void addq(int ptr) {
/* remove a member from the front of the queue */
int popq() {
int popq( void ) {
int ptr;
if ( !emptyq() ) {
@ -198,7 +198,7 @@ void fgEventRun(int ptr) {
/* Initialize the scheduling subsystem */
void fgEventInit() {
void fgEventInit( void ) {
printf("Initializing event manager\n");
event_ptr = 0;
initq();
@ -207,7 +207,9 @@ void fgEventInit() {
/* Register an event with the scheduler, returns a pointer into the
* event table */
int fgEventRegister(char *desc, void (*event)(), int status, int interval) {
int fgEventRegister(char *desc, void (*event)( void ), int status,
int interval)
{
struct fgEVENT *e;
e = &events[event_ptr];
@ -240,27 +242,27 @@ int fgEventRegister(char *desc, void (*event)(), int status, int interval) {
/* Update the scheduling parameters for an event */
void fgEventUpdate() {
void fgEventUpdate( void ) {
}
/* Delete a scheduled event */
void fgEventDelete() {
void fgEventDelete( void ) {
}
/* Temporarily suspend scheduling of an event */
void fgEventSuspend() {
void fgEventSuspend( void ) {
}
/* Resume scheduling and event */
void fgEventResume() {
void fgEventResume( void ) {
}
/* Dump scheduling stats */
void fgEventPrintStats() {
void fgEventPrintStats( void ) {
int i;
if ( event_ptr > 0 ) {
@ -283,7 +285,7 @@ void fgEventPrintStats() {
/* Add pending jobs to the run queue and run the job at the front of
* the queue */
void fgEventProcess() {
void fgEventProcess( void ) {
#ifdef USE_FTIME
struct timeb current;
#else
@ -336,9 +338,13 @@ void fgEventProcess() {
/* $Log$
/* Revision 1.5 1998/01/06 01:20:27 curt
/* Tweaks to help building with MSVC++
/* Revision 1.6 1998/01/19 18:40:39 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.5 1998/01/06 01:20:27 curt
* Tweaks to help building with MSVC++
*
* Revision 1.4 1997/12/31 17:46:50 curt
* Tweaked fg_time.c to be able to use ftime() instead of gettimeofday()
*

View file

@ -30,34 +30,39 @@
/* Initialize the scheduling subsystem */
void fgEventInit();
void fgEventInit( void );
/* Register an event with the scheduler, returns a pointer into the
* event table */
int fgEventRegister(char *desc, void (*event)(), int status, int interval);
int fgEventRegister(char *desc, void (*event)( void ), int status,
int interval);
/* Update the scheduling parameters for an event */
void fgEventUpdate();
void fgEventUpdate( void );
/* Delete a scheduled event */
void fgEventDelete();
void fgEventDelete( void );
/* Temporarily suspend scheduling of an event */
void fgEventSuspend();
void fgEventSuspend( void );
/* Resume scheduling and event */
void fgEventResume();
void fgEventResume( void );
/* Dump scheduling stats */
void fgEventPrintStats();
void fgEventPrintStats( void );
/* Add pending jobs to the run queue and run the job at the front of
* the queue */
void fgEventProcess();
void fgEventProcess( void );
/* $Log$
/* Revision 1.1 1997/12/30 04:19:22 curt
/* Initial revision.
/* Revision 1.2 1998/01/19 18:40:39 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.1 1997/12/30 04:19:22 curt
* Initial revision.
*
*/

View file

@ -44,7 +44,7 @@ unsigned long int fgSimTime;
/* This routine catches the SIGALRM */
void fgTimerCatch() {
void fgTimerCatch( void ) {
/* ignore any SIGALRM's until we come back from our EOM iteration */
signal(SIGALRM, SIG_IGN);
@ -87,7 +87,7 @@ void fgTimerInit(float dt, void (*f)()) {
/* This function returns the number of milleseconds since the last
time it was called. */
int fgGetTimeInterval() {
int fgGetTimeInterval( void ) {
int interval;
static int inited = 0;
@ -131,9 +131,13 @@ int fgGetTimeInterval() {
/* $Log$
/* Revision 1.7 1997/12/30 13:06:58 curt
/* A couple lighting tweaks ...
/* Revision 1.8 1998/01/19 18:40:39 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.7 1997/12/30 13:06:58 curt
* A couple lighting tweaks ...
*
* Revision 1.6 1997/07/12 02:13:04 curt
* Add ftime() support for those that don't have gettimeofday()
*

View file

@ -33,20 +33,24 @@ extern unsigned long int fgSimTime;
/* this routine initializes the interval timer to generate a SIGALRM
* after the specified interval (dt) the function f() will be called
* at each signal */
void fgTimerInit(float dt, void (*f)());
void fgTimerInit( float dt, void (*f)( void ) );
/* This function returns the number of milleseconds since the last
time it was called. */
int fgGetTimeInterval();
int fgGetTimeInterval( void );
#endif /* FG_TIMER_H */
/* $Log$
/* Revision 1.2 1997/07/23 21:52:27 curt
/* Put comments around the text after an #endif for increased portability.
/* Revision 1.3 1998/01/19 18:40:40 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.2 1997/07/23 21:52:27 curt
* Put comments around the text after an #endif for increased portability.
*
* Revision 1.1 1997/06/16 19:24:20 curt
* Initial revision.
*

View file

@ -261,7 +261,7 @@ void fgSunPosition(time_t ssue, double *lon, double *lat) {
/* update the cur_time_params structure with the current sun position */
void fgUpdateSunPos() {
void fgUpdateSunPos( void ) {
struct fgLIGHT *l;
struct fgTIME *t;
struct fgVIEW *v;
@ -373,9 +373,13 @@ void fgUpdateSunPos() {
/* $Log$
/* Revision 1.21 1997/12/30 23:10:19 curt
/* Calculate lighting parameters here.
/* Revision 1.22 1998/01/19 18:40:40 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.21 1997/12/30 23:10:19 curt
* Calculate lighting parameters here.
*
* Revision 1.20 1997/12/30 22:22:43 curt
* Further integration of event manager.
*

View file

@ -45,7 +45,7 @@
#include "../Include/types.h"
/* update the cur_time_params structure with the current sun position */
void fgUpdateSunPos();
void fgUpdateSunPos( void );
void fgSunPosition(time_t ssue, double *lon, double *lat);

View file

@ -34,7 +34,7 @@ struct fgWEATHER current_weather;
/* Initialize the weather modeling subsystem */
void fgWeatherInit(void) {
void fgWeatherInit( void ) {
struct fgWEATHER *w;
w = &current_weather;
@ -49,7 +49,7 @@ void fgWeatherInit(void) {
/* Update the weather parameters for the current position */
void fgWeatherUpdate() {
void fgWeatherUpdate( void ) {
struct fgFLIGHT *f;
struct fgWEATHER *w;
@ -64,9 +64,13 @@ void fgWeatherUpdate() {
/* $Log$
/* Revision 1.10 1997/12/30 22:22:46 curt
/* Further integration of event manager.
/* Revision 1.11 1998/01/19 18:40:41 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.10 1997/12/30 22:22:46 curt
* Further integration of event manager.
*
* Revision 1.9 1997/12/30 20:48:03 curt
* Integrated new event manager with subsystem initializations.
*

View file

@ -37,19 +37,23 @@ extern struct fgWEATHER current_weather;
/* Initialize the weather modeling subsystem */
void fgWeatherInit(void);
void fgWeatherInit( void );
/* Update the weather parameters for the current position */
void fgWeatherUpdate();
void fgWeatherUpdate( void );
#endif /* WEATHER_H */
/* $Log$
/* Revision 1.6 1997/12/30 22:22:47 curt
/* Further integration of event manager.
/* Revision 1.7 1998/01/19 18:40:41 curt
/* Tons of little changes to clean up the code and to remove fatal errors
/* when building with the c++ compiler.
/*
* Revision 1.6 1997/12/30 22:22:47 curt
* Further integration of event manager.
*
* Revision 1.5 1997/12/10 22:37:56 curt
* Prepended "fg" on the name of all global structures that didn't have it yet.
* i.e. "struct WEATHER {}" became "struct fgWEATHER {}"