1
0
Fork 0
Commit graph

267 commits

Author SHA1 Message Date
curt
49fc684885 Tweaks to binobj reader interface. 2001-01-06 05:09:40 +00:00
curt
66650e4148 1. Added src/Main/fgfs.hxx as a standard, top-level include file for
FlightGear subsystems -- it isolates some of the config and #ifdef
stuff in a single place.

2. Added a new FGSubsystem interface, defined in fgfs.hxx; so far,
only FGControls implements it, but if that works, we can start letting
it propagate through the system and simplify the code in main.cxx and
fg_init.cxx (which is terrifyingly complex for anyone new to the
project).

3. Added new src/Main/fgfs_props.[hc]xx files with convenience
functions for tying properties under FlightGear.

4. Experimentally modified src/Controls/controls.cxx to tie properties
directly (rather than tying to BFI functions).  I'd appreciate it if
you could get this into CVS as soon as possible, so we can see if the
template stuff causes trouble for any other platforms before I add
properties to the other subsystems.

5. Miscellaneous superficial modifications to other files.


In addition, I've made a couple of further changes:


6. Modified BFI to add support for setting the view axes (i.e. with a
joystick hat).

7. Cleaned up bfi.cxx and removed all cout statements.
2001-01-05 17:38:58 +00:00
curt
5ef00ab621 Contibuted by David Megginson; Initial revision. 2001-01-05 17:37:59 +00:00
curt
3e7bc24006 Tweaks related to the HUD. 2001-01-05 16:45:14 +00:00
curt
3b88c71122 Applied changes relative to David Megginson's property manager rewrite. 2000-12-19 23:29:16 +00:00
curt
6d399f83f8 Added some initial support for moving parts on aircraft models. 2000-12-19 20:50:00 +00:00
curt
0d457e78e2 Fix a view bug that could make the aircraft appear rotated from an
external view if the primary view was rotated before we switched.
2000-12-14 21:59:47 +00:00
curt
e333080388 MacOS changes contributed by Darrell Walisser (12/13/2000) 2000-12-13 23:02:02 +00:00
curt
95d6d93bed Renamed FGBucket -> SGBucket. 2000-12-13 20:36:04 +00:00
curt
403c740b34 Updates to DCS support and updates to options in preparation for support
the new xml configurable hud.
2000-12-08 20:05:43 +00:00
curt
94fd1bd8f2 Blame this on David Megginson ... :-)
Save/restore seems to be working now, thanks to a couple of
unspeakable kludges:

1. Every time the altitude changes, pause the flight simulator for
five frames and then change it a second time.

2. Every time the latitude or longitude changes, wait five frames,
then invoke fgUpdateSkyAndLightingParams() a second time.
2000-12-08 17:36:07 +00:00
curt
6574e8f4f6 Updates to time parsing and setting by David Megginson. 2000-12-08 17:26:49 +00:00
curt
5fecec2bba More night ground lighting tweaks. 2000-12-06 22:16:12 +00:00
curt
31b9c763df Added a --visibility= option. 2000-12-06 04:13:16 +00:00
curt
2baba715b4 Adjust ground lighting up significantly higher to avoid zbuffer fighting
on cards with 16 bit (or less) depth buffers.
2000-12-05 14:27:27 +00:00
curt
45564beba8 Fix fog / light punchthrough. 2000-12-04 22:35:10 +00:00
curt
3f32f2680d Started laying out infrastructure for ground lighting.
Renamed fg_random -> sg_random.
2000-12-04 05:26:40 +00:00
curt
11987d96c3 Removed tile radius option. Range of tiles to be loaded is now controled
by the visibility distance.
2000-12-03 20:13:58 +00:00
curt
57a4c79eb5 Moved Time/timestamp.hxx into simgear/timing/timestamp.hxx 2000-11-30 18:43:31 +00:00
curt
bde6c86fce Parse route files by Durk Talsma. 2000-11-28 23:38:24 +00:00
curt
3593f3782d Fixes for better control over external aircraft 3d model control. 2000-11-14 20:43:38 +00:00
curt
5175227e3b Tweaks. 2000-11-03 23:04:23 +00:00
curt
08fd9cc36d Moved fov and win_ration from FGOptions to FGViewer so we can control these
on a per view basis.
Fixed some compile warnings in Main/*.cxx
2000-11-01 23:27:32 +00:00
curt
f24b6a4098 More view clean ups. 2000-11-01 22:40:10 +00:00
curt
6786cf9da4 src/GUI/gui.cxx:
- removed Toggle Clouds menu item

src/Main/options.cxx:
- (minor) added some code to sync up options with properties

src/Main/bfi.[ch]xx:
- removed (get|set)Clouds(ASL)?
- removed setSpeedNorth, setSpeedEast, and setSpeedDown -- these are
  all read-only now
- added setAirspeed (for calibrated kt)
- extensive rewrite to support Tony's FDM changes
- rearranged everything in bfi.hxx to mess up Curt's ediff examination
- added properties for setting initial panel position

src/Main/save.cxx:
- reinit the tile cache after restore
2000-11-01 04:51:55 +00:00
curt
8aab71034a Woohoo! some success with external views ... 2000-11-01 04:32:04 +00:00
curt
49aab2af8e Working on lookat views. 2000-11-01 02:30:10 +00:00
curt
1b206c6202 Tweaks. 2000-10-30 15:09:17 +00:00
curt
11a68e55d4 Updates by Tony working on the FDM interface bus. 2000-10-28 16:30:30 +00:00
curt
81bb2f00d1 Added manifold pressure to the property manager. 2000-10-27 22:27:16 +00:00
curt
b83ad15313 Added CHT (cylinder head temp) to BFI and property manager. 2000-10-27 22:00:43 +00:00
curt
cf6022e439 Added a viewmgr system and made corresponding changes to support it. 2000-10-26 21:51:09 +00:00
curt
f519b98e16 Initial revision. 2000-10-26 21:23:38 +00:00
curt
1338b3548c Debug cleanup. 2000-10-26 18:20:55 +00:00
curt
35819b8c4d Check point ... making progress with a FGViewerLookAt class so we can
more easily do nifty external views.
2000-10-26 18:10:28 +00:00
curt
0175b4cd25 Continued FGViewer cleanups. FGViewer is now a base class so that we can
derive specific viewer classes from it.  Here's what I currently have in mind:

FGViewer
  |
  |-> FGViewerPRH     (current system with orientation specified in
  |                    LaRCsim Euler angle convention)
  |
  |-> FGViewerLookAt  Feed in a position, view direction, and up vector
  |
  |-> FGViewerHPR     (similar to PRH, but using ssg hpr euler angle
  |                    convention)
  |-> others?
2000-10-25 22:59:02 +00:00
curt
f4ce3314fd Initial revision. 2000-10-25 22:58:05 +00:00
curt
83ad798898 Removed references to Point3D from FGViewers interface. 2000-10-25 19:46:43 +00:00
curt
470ee55fb7 Continuing work on cleanups.
Removed some commented out chunks of code that no longer make sense to keep
around.
Working on replacing instances of Point3D with sg{d,}Vec3.
2000-10-25 19:27:13 +00:00
curt
6515f9072c Checkpoint commit for cleaning up the FGViewer class. External views are
not working right, but this will hopefully be fixed soon.
2000-10-25 15:27:55 +00:00
curt
7cc98ad15f I tested:
LaRCsim c172 on-ground and in-air starts, reset: all work
UIUC Cessna172 on-ground and in-air starts work as expected, reset
results in an aircraft that is upside down but does not crash FG.   I
don't know what it was like before, so it may well be no change.
JSBSim c172 and X15 in-air starts work fine, resets now work (and are
trimmed), on-ground starts do not -- the c172 ends up on its back.  I
suspect this is no worse than before.

I did not test:
Balloon (the weather code returns nan's for the atmosphere data --this
is in the weather module and apparently is a linux only bug)
ADA (don't know how)
MagicCarpet  (needs work yet)
External (don't know how)

known to be broken:
LaRCsim c172 on-ground starts with a negative terrain altitude (this
happens at KPAO when the scenery is not present).   The FDM inits to
about 50 feet AGL and the model falls to the ground.  It does stay
upright, however, and seems to be fine once it settles out, FWIW.

To do:
--implement set_Model on the bus
--bring Christian's weather data into JSBSim
-- add default method to bus for updating things like the sin and cos of
latitude (for Balloon, MagicCarpet)
-- lots of cleanup

The files:
src/FDM/flight.cxx
src/FDM/flight.hxx
-- all data members now declared protected instead of private.
-- eliminated all but a small set of 'setters', no change to getters.
-- that small set is declared virtual, the default implementation
provided preserves the old behavior
-- all of the vector data members are now initialized.
-- added busdump() method -- FG_LOG's  all the bus data when called,
useful for diagnostics.

src/FDM/ADA.cxx
-- bus data members now directly assigned to

src/FDM/Balloon.cxx
-- bus data members now directly assigned to
-- changed V_equiv_kts to V_calibrated_kts

src/FDM/JSBSim.cxx
src/FDM/JSBSim.hxx
-- bus data members now directly assigned to
-- implemented the FGInterface virtual setters with JSBSim specific
logic
-- changed the static FDMExec to a dynamic fdmex (needed so that the
JSBSim object can be deleted when a model change is called for)
-- implemented constructor and destructor, moved some of the logic
formerly in init() to constructor
-- added logic to bring up FGEngInterface objects and set the RPM and
throttle values.

src/FDM/LaRCsim.cxx
src/FDM/LaRCsim.hxx
-- bus data members now directly assigned to
-- implemented the FGInterface virtual setters with LaRCsim specific
logic, uses LaRCsimIC
-- implemented constructor and destructor, moved some of the logic
formerly in init() to constructor
-- moved default inertias to here from fg_init.cxx
-- eliminated the climb rate calculation.  The equivalent, climb_rate =
-1*vdown, is now in copy_from_LaRCsim().

src/FDM/LaRCsimIC.cxx
src/FDM/LaRCsimIC.hxx
-- similar to FGInitialCondition, this class has all the logic needed to
turn data like Vc and Mach into the more fundamental quantities LaRCsim
needs to initialize.
-- put it in src/FDM since it is a class

src/FDM/MagicCarpet.cxx
 -- bus data members now directly assigned to

src/FDM/Makefile.am
-- adds LaRCsimIC.hxx and cxx

src/FDM/JSBSim/FGAtmosphere.h
src/FDM/JSBSim/FGDefs.h
src/FDM/JSBSim/FGInitialCondition.cpp
src/FDM/JSBSim/FGInitialCondition.h
src/FDM/JSBSim/JSBSim.cpp
-- changes to accomodate the new bus

src/FDM/LaRCsim/atmos_62.h
src/FDM/LaRCsim/ls_geodesy.h
-- surrounded prototypes with #ifdef __cplusplus ... #endif , functions
here are needed in LaRCsimIC

src/FDM/LaRCsim/c172_main.c
src/FDM/LaRCsim/cherokee_aero.c
src/FDM/LaRCsim/ls_aux.c
src/FDM/LaRCsim/ls_constants.h
src/FDM/LaRCsim/ls_geodesy.c
src/FDM/LaRCsim/ls_geodesy.h
src/FDM/LaRCsim/ls_step.c
src/FDM/UIUCModel/uiuc_betaprobe.cpp
-- changed PI to LS_PI, eliminates preprocessor naming conflict with
weather module

src/FDM/LaRCsim/ls_interface.c
src/FDM/LaRCsim/ls_interface.h
-- added function ls_set_model_dt()

src/Main/bfi.cxx
-- eliminated calls that set the NED speeds to body components.  They
are no longer needed and confuse the new bus.

src/Main/fg_init.cxx
-- eliminated calls that just brought the bus data up-to-date (e.g.
set_sin_cos_latitude). or set default values.   The bus now handles the
defaults and updates itself when the setters are called (for LaRCsim and
JSBSim).  A default method for doing this needs to be added to the bus.
-- added fgVelocityInit() to set the speed the user asked for.  Both
JSBSim and LaRCsim can now be initialized using any of:
vc,mach, NED components, UVW components.

src/Main/main.cxx
--eliminated call to fgFDMSetGroundElevation, this data is now 'pulled'
onto the bus every update()

src/Main/options.cxx
src/Main/options.hxx
-- added enum to keep track of the speed requested by the user
-- eliminated calls to set NED velocity properties to body speeds, they
are no longer needed.
-- added options for the NED components.

src/Network/garmin.cxx
src/Network/nmea.cxx
--eliminated calls that just brought the bus data up-to-date (e.g.
set_sin_cos_latitude).  The bus now updates itself when the setters are
called (for LaRCsim and JSBSim).  A default method for doing this needs
to be added to the bus.
-- changed set_V_equiv_kts to set_V_calibrated_kts.  set_V_equiv_kts no
longer exists ( get_V_equiv_kts still does, though)

src/WeatherCM/FGLocalWeatherDatabase.cpp
-- commented out the code to put the weather data on the bus, a
different scheme for this is needed.
2000-10-24 00:34:50 +00:00
curt
c67e0467b4 Tweaks. 2000-10-23 20:27:41 +00:00
curt
152a5902c8 Moved winWidth and winHeight out of FGViewer since these are set on a
per-application level.  We can have multiple viewers ...
Cleaned up fov mistake on startup with panel activated.
2000-10-19 23:09:33 +00:00
curt
01c44cbb99 Code clean ups relating to FGOptions ... and moved it into globals-> space. 2000-10-19 21:24:43 +00:00
curt
ce574d59f5 The following changes were made to flightgear-0.7.5 code to implement the follow
ing features:

a) ADA Flight model - ADA.cxx, ADA.hxx, flight.hxx
b) Fighter a/c HUD       - flight.hxx, hud.hxx, hud.cxx, cockpit.cxx, hud_ladr.c
xx, hud_card.cxx
c) 3-window display      - options.hxx, options.cxx, viewer.cxx
d) Moving objects (ship) - main.cxx
e) Patches               - main.cxx

ADA.cxx, ADA.hxx
--------------------------
Interface to the external ADA flight dynamics package.

flight.hxx
----------
Included prototypes for accepting additional data fron the External flight
model for fighter aircraft HUD

Hud.hxx
-------
Included prototypes for accepting additional data for fighter HUD from Exernal F
light model.
Defined FIGHTER_HUD pre-processor directive to enable compilation of fighter hud
 code.

hud.cxx, cockpit.cxx, hud_ladr.cxx, hud_card.cxx
---------------------------------------
Included code to initialise additional reticles/text for fighter HUD which is co
nditionally
compiled if FIGHTER_HUD is defined.

options.hxx
-----------
Added window_offset, and function to retrieve its value for 3 windows

options.cxx
-----------
Changed few options to suit ADA/CEF projection system/screens and checks for win
dow offset.

views.cxx
---------
Added code to retrieve view offset for window.

Main.cxx
--------
Added code to load and move an aircraft carrier.
Patch to enable clouds from command line until Curtis fixes it. By default cloud
s are disabled.
2000-10-19 19:46:13 +00:00
curt
2eda8480e9 Some changes contributed by David Megginson to allow for more interesting
external views.
2000-10-18 21:19:30 +00:00
curt
806511bd99 Added ref() count increment calls to all ssgSimpleState creation to prevent
them from being delete by ssg once nothing in the scene graph points to them.
2000-10-18 00:48:12 +00:00
curt
e178af50f0 Check result of cur_fdm_state->init() and die if it fails. 2000-10-16 14:55:34 +00:00
curt
5018278831 Panel tweaks to support "shaped" panels.
Additional HUD support for waypoints.
JSBSim updates.
2000-10-13 23:34:54 +00:00
curt
df0228e019 Tweaks and massaging relative to the new waypoint route management system.
You can now specify waypoint on the command line with --wp=ID[,alt]
2000-10-12 01:08:09 +00:00