1
0
Fork 0
Commit graph

5588 commits

Author SHA1 Message Date
daveluff
7019fcdc15 Fix a seg fault that could be caused if all no AI models were in existance. Ssg could then free the memory pointed to by our pointer behind our back, causing it to crash when next approaching a controlled airport requiring an AI model. Fix is to hold one ref to each model in the AIMgr at all times. 2004-04-11 15:20:36 +00:00
andy
d27ba7f2d2 Numeric keypad handling 2004-04-09 15:57:16 +00:00
andy
53e470ad0c Don't ask for 32 bit depth buffer. Some cards do only 24, leaving 8
for the alpha channel.
2004-04-09 14:52:03 +00:00
ehofman
b0a3ce0fc0 First attempt to make it possible to use either SDL or glut at compile time. 2004-04-07 14:42:41 +00:00
andy
049fda00cf Fix more brain damage with keyboard handling. I think everything is
working now.
2004-04-06 23:47:56 +00:00
andy
96afa68cad Fix brain damage in previous fix. 2004-04-06 22:17:25 +00:00
andy
163d2c5105 Fix bug where key releases got reported as presses. 2004-04-06 21:55:49 +00:00
andy
395c9bc638 API changes to get fullscreen mode working with SDL. It can't switch
modes after creating the window, so it needs a flag in
fgOSOpenWindow().
2004-04-06 14:28:22 +00:00
ehofman
34b0b5220c Windows fix. 2004-04-06 14:25:33 +00:00
andy
86d4fcf5b6 Added mouse cursor definitions stolen from the X11 cursor font (via a
pointer from Melchior to a font editor that could read .pcf and
generate image files)
2004-04-06 04:06:11 +00:00
andy
941f99308d Oops. A change to an upstream header seems to have remove glu.h, which
these files require.  Dunno why my build didn't pick up the transitive
dependency.
2004-04-06 03:51:11 +00:00
andy
897cc6295c Need to include fg_os.hxx, so the PUI initialization picks the right library. 2004-04-05 21:51:16 +00:00
andy
52a2f92009 Early-access version of an SDL implementation of the fg_os API. It works,
but is not integrated into the build process.  It also lacks support for
changing mouse cursors, which works rather differently in SDL vs. Glut.
2004-04-05 21:39:32 +00:00
andy
f46f962ca0 Revert the hard-coded keybindings I just replaced, and turn them into real
command bindings accessible from XML.  This still probably isn't a final
solution (which would drive the HUD from propery values), but it's a step
in the right direction anyway.
2004-04-05 19:38:50 +00:00
andy
27290ab0ef Restore the hard-coded HUD keybindings that I inadvertently killed
during deglutification.
2004-04-05 18:54:53 +00:00
curt
0490631250 Jim Wilson:
This update contains a change to not overwrite the altitude-ft preset during
"onground" start.  The change also prevents a ground trim issue with the
JSBSim fdm when a "reset" is done by FlightGear.
2004-04-05 16:47:13 +00:00
ehofman
e30112a5ca Frederic Bouvier:
this patch is to clear a problem that I sometimes
encounter : FG locks when hitting the cancel button
of a dialog. In fact, an interator is always invalid
when it was used to erase a member of a collection.
The braces are here to help my debugger, and I also
removed a warning about unused variable.
2004-04-05 11:29:12 +00:00
david
81929e4726 Ignore generated GPL. 2004-04-04 20:56:26 +00:00
david
62345d2c90 Added more generated files. 2004-04-04 14:21:26 +00:00
ehofman
966e0bdd4d Frederic Bouvier:
I restored the output to cout / cerr
for the options and the warning for the version mismatch.
There is a dummy SG_LOG to allow the windows version to
popup the console.

The snapshot rendering use multipass now.
2004-04-03 09:27:38 +00:00
ehofman
7902c04905 Plib is willing callbacks to return 0, 1 or 2 and not simply a boolean 2004-04-02 19:49:51 +00:00
ehofman
ace81503d6 Match the changes in SimGear to fix an NVidia problem. 2004-04-02 19:44:42 +00:00
ehofman
7c616bb5bd Frederic Bouvier:
Cure the performance penalty that leads to draw the aircraft twice.
Also cure the transparency bug over the aircraft.
2004-04-02 16:50:38 +00:00
curt
aa2541a776 Towards better support for a per engine master bat/alt switch. 2004-04-02 16:20:46 +00:00
curt
8d952961cf reflect net_ftm/net_ctrls changes. 2004-04-02 16:20:17 +00:00
curt
ec036a7be8 native_ctrls:
- We need to be able to support a per engine master bat/alt switch.
- Forgot to write the gear level state into the network structure.

native_fdm:
- renamed EGT->egt for consistancy.
- added manifold pressure to the structure.
2004-04-02 16:19:59 +00:00
curt
b5c9a3c0e2 Clean up some debugging output. 2004-04-02 16:17:08 +00:00
ehofman
4e6a009476 Frederic Bouvier:
Add a select method to FGAircraftModel to draw the aircraft
  or not when calling ssgCullAndDraw on the whole scene.
2004-04-02 14:43:31 +00:00
ehofman
b34f0711c4 Frederic Bouvier:
Add a static function that will be installed as a callback to
  cull or not the terrain leaves in tiles.
  Add a function to set the filter.
2004-04-02 14:42:42 +00:00
ehofman
c98daef926 Frederic Bouvier:
Add a pretrav callback to the first kid of geometry that should
  be the terrain_branch. The callback is a static function in
  FGTileMgr
2004-04-02 14:42:03 +00:00
ehofman
924e95fec2 Frederic Bouvier:
Call sgLoad3DModel from simgear instead of duplicating code.
2004-04-02 14:41:35 +00:00
ehofman
dba02e35d4 Frederic Bouvier:
FG_ENABLE_MULTIPASS_CLOUDS must be defined to enable
 the algorithm. I made this because the stencil buffer
 must be initialized at the beginning of the program and
 OpenGL can fallback to software rendering if it can't
 find a visual with stencil buffer. I didn't touch the
 configure script, so CXXFLAGS=-DFG_ENABLE_MULTIPASS_CLOUDS
 must be set before running ./configure.

 If FG_ENABLE_MULTIPASS_CLOUDS is defined, the main render
 loop begins by reading the /sim/rendering/multi-pass-clouds
 property. It is a boolean property so there are only two
 quality levels. false means no multi pass and no use of
 the stencil buffer, true means an additionnal pass for
 both upper and lower cloud layers.

 The algorithms are as follow :
  /sim/rendering/multi-pass-clouds=false
   1. draw sky dome
   2. draw terrain only
   3. draw clouds above the viewer
   4. draw models except the aircraft
   5. draw clouds below the viewer
   6. draw the aircraft.
  The cloud rendering doesn't update the depth buffer.
  This means that models overwrite clouds above the viewer.
  This is only noticeable for tall buildings and when
  flying very low. Also, drawing low clouds after models
  means that they are not blended with models' translucent
  surfaces. Large transparent area require alpha test
  enabled and AI aircraft canopy are making holes. The
  pilot's aircraft being rendered at the end, there is no
  problem with canopy or prop disc.

  /sim/rendering/multi-pass-clouds=true
   1. draw the sky dome
   2. draw the terrain only
   3. draw all clouds
   4. draw models except the aircraft
   5. redraw the clouds where the models where drawn ( stencil
      test on )
   6. draw the aircraft
  The assumptions made by this algoritm are that the terrain
  is not transparent ( should be true in all cases and
  that there are no clouds between the aircraft and the viewer.
  Assuming these facts, there should be no blending bugs.

  The screenshot rendering is not updated yet.
2004-04-02 14:40:54 +00:00
curt
92010f9f94 Clean up a couple bugs in the multiengine handling of the net_fdm.hxx
external interface.
2004-04-02 01:54:38 +00:00
andy
95e8b63988 I was too agressive in the fg_os port. Glut doesn't support grabbing
the keyboard modifiers outside of a key event handler, so adding the
fgGetKeyModifiers() call to doMouseMotion was broken.  The user could
see "phantom" modifier keys.
2004-04-01 23:28:47 +00:00
andy
ae2dbe4f25 Re-enable glut game mode for now 2004-04-01 15:44:13 +00:00
curt
2acdd02879 Clean up various compiler warnings that have crept into the code. This
by no means get's them all, but it's a start.
2004-04-01 15:27:53 +00:00
andy
db79413b6e Win32 typos crept in during the patch. Fix from Frederic Bouvier. 2004-04-01 15:14:34 +00:00
curt
a3b6a593d6 Don't include an unnecessary header. 2004-03-31 23:53:51 +00:00
andy
c0b4531d04 Yank out all the glut dependencies and concentrate them in a (easily
reimplementable) Main/fg_os.cxx file.
2004-03-31 21:10:32 +00:00
ehofman
d430290e48 Frederic Bouvier:
trying the --show-aircraft option, I noticed that I had
no output. This is because there are still output to
cout or cerr, that are not triggering my console patch
for windows. The patch attached use SG_LOG instead.
A request to hit a key is also added because otherwise,
the console window will disappear as soon as the program
stop.

This problem is minor though given the fact that fgfs.exe
is shipped with fgrun that do show the available aircraft
in a much nicer manner.
2004-03-30 09:05:05 +00:00
curt
29d9c1b2f6 Initial 0.9.4 setup file. 2004-03-29 20:57:11 +00:00
curt
cbc51e84e6 Make sure fgadmin get's into future release tar balls. 2004-03-29 17:42:10 +00:00
daveluff
e1d1bdc1da A few abs->fabs where we are passing a double in 2004-03-29 10:25:21 +00:00
daveluff
0bea768f24 Patch from Fred Bouvier to use multi-platform ul library from plib for directory searching instead of ifdefs 2004-03-29 10:20:19 +00:00
andy
dc41cdb948 More work to get the starter behavior right, without breaking David's
work on the pa28 idle and without creating ridiculous side effects
(like being able to fly the aircraft with the starter motor, heh).
This one looks pretty good for now, pending work on the propeller to
get its low speed drag in line with reality.
2004-03-27 18:34:04 +00:00
ehofman
199aa53157 Add the IRIX packaging files for use with swpkg 2004-03-27 15:16:03 +00:00
andy
c62048d5e2 YASim now supports the new fuel.nas fuel management system. It
reads the /consumables tree for input to determine weights, but
places output only in /engines/engine[n]/fuel-consumed-lbs where
it gets picked up by the Nasal code.
2004-03-27 04:07:18 +00:00
andy
17b6142a76 Tune up the starter torque to match the recent changes to engine
friction.  We should get these better calibrated at some point...
2004-03-26 22:53:41 +00:00
curt
0c01cebfc3 Final 0.9.4 tweaks. 2004-03-26 21:46:49 +00:00
andy
3ddfd77781 Forgot to handle "unspecified" properties in getprop(). Treat them
as strings.
2004-03-24 19:06:54 +00:00