]> git.mxchange.org Git - flightgear.git/log
flightgear.git
19 years ago- rename initModule() to createModule() (as suggested by Andy)
mfranz [Sun, 19 Jun 2005 17:09:03 +0000 (17:09 +0000)]
- rename initModule() to createModule()  (as suggested by Andy)
- make it public
- enable handleCommand() to execute a binding (or other nasal code defined
  in a property system subtree) in a particular namespace (-> "module" child)

19 years agoJosh Babcock: fix typo
mfranz [Fri, 17 Jun 2005 19:42:25 +0000 (19:42 +0000)]
Josh Babcock: fix typo

19 years agoAdjust logging output.
curt [Tue, 14 Jun 2005 20:55:46 +0000 (20:55 +0000)]
Adjust logging output.

19 years agoMake readScriptFile() public, and rename it to loadModule(), so that external
andy [Tue, 14 Jun 2005 19:57:24 +0000 (19:57 +0000)]
Make readScriptFile() public, and rename it to loadModule(), so that external
code can have access to the facility for loading modules from files.

Also includes a cast-int-to-pointer fix that causes a warning on 64 bit
systems.

19 years agoUpdated electrical system.
curt [Tue, 14 Jun 2005 17:57:48 +0000 (17:57 +0000)]
Updated electrical system.

These changes represent some attempts to bandaid and patch a hopelessly
flawed system to impliment basic battery charging/discharging as well as
provide the ability to model ammeter gauges and draw current from multiple
sources (like load balancing multiple alternators in a multi-engine aircraft.)
The system design forces all these things to be horrible hacks or depend
on extremely subtle system side effects and call ordering so they may or9
may not work to one degree or another.

As mentioned in the mailing list, my recommendation is to move away from
using this system and instead build a procedural electrical system using
nasal.  Sometime in the future we hopefully can impliment a better conceived
data driven electrical system model.

19 years agoTurn the electrical system into a non-hardcoded system like all the other
curt [Tue, 14 Jun 2005 17:54:19 +0000 (17:54 +0000)]
Turn the electrical system into a non-hardcoded system like all the other
systems.

19 years agoFix a misuse of a return value that lead to an error message being displayed
curt [Tue, 14 Jun 2005 17:53:40 +0000 (17:53 +0000)]
Fix a misuse of a return value that lead to an error message being displayed
when one shouldn't have been.

19 years agoUpdated notes on the FG electrical system model.
curt [Tue, 14 Jun 2005 17:52:16 +0000 (17:52 +0000)]
Updated notes on the FG electrical system model.

19 years agostrip trailing spaces & garbage
mfranz [Mon, 13 Jun 2005 19:27:40 +0000 (19:27 +0000)]
strip trailing spaces & garbage

19 years agorevert last patch, and do it differently: set /input/joysticks/which (int)
mfranz [Mon, 13 Jun 2005 06:14:45 +0000 (06:14 +0000)]
revert last patch, and do it differently: set /input/joysticks/which (int)
to the joystick index (x in /input/joysticks/js[x]) both when initializing
nasal init blocks & whenever updating the joystick. That's the only way to
make these nasal contexts aware of the joytick for which they were called.
And that's useful if a js maintains common variables, such as modifiers or
state variables, that should be shared between the namespace-less bindings
and initialization code. And, yes, it's over-engineered ...  :-)

19 years agoleave temporary hint for the nasal init block, so that it can access
mfranz [Sun, 12 Jun 2005 19:27:20 +0000 (19:27 +0000)]
leave temporary hint for the nasal init block, so that it can access
its own data, and can distinguish itself from other instances of the
same js driver. This property is removed after script execution.
Example:

  self = props.globals.getNode(getprop("/input/joysticks/this"));

19 years agosg_throwable's "origin" argument is optional and defaults to an empty
mfranz [Sun, 12 Jun 2005 16:01:49 +0000 (16:01 +0000)]
sg_throwable's "origin" argument is optional and defaults to an empty
string. "(received from )" doesn't really look good.

19 years agoeven clearer error message :-/
mfranz [Sun, 12 Jun 2005 13:54:27 +0000 (13:54 +0000)]
even clearer error message :-/

19 years agoclearer error message
mfranz [Sun, 12 Jun 2005 13:51:55 +0000 (13:51 +0000)]
clearer error message

19 years agoa missing /input/joysticks/ node is no alarming sign any more. It's
mfranz [Sun, 12 Jun 2005 13:35:55 +0000 (13:35 +0000)]
a missing /input/joysticks/ node is no alarming sign any more. It's
supposed to get populated from $FG_ROOT/Input/Joysticks/.

19 years agothrow an exception if not even a default joystick could be found;
mfranz [Sat, 11 Jun 2005 15:26:32 +0000 (15:26 +0000)]
throw an exception if not even a default joystick could be found;
This can only happen if $FG_ROOT is corrupted or some developer has
broken the default js config. Better not keep that under the rug.

19 years ago- read all joystick files from $FG_ROOT/Input/Joysticks automatically
mfranz [Sat, 11 Jun 2005 14:26:11 +0000 (14:26 +0000)]
- read all joystick files from $FG_ROOT/Input/Joysticks automatically
  (no need to list the paths explicitly in $FG_ROOT/joysticks.xml any more)
- move identified js nodes to /input/joysticks/js[0-9], but
- don't overwrite already set joystick data there
- remove all nodes when they aren't used any more
- add "id" node, which contains the js id that lead to the selection
  of a "named js" config
- add "source" node containing the path of the used js config file
- execute all nasal script groups at initialization time

19 years agocall the subsystems' postinit() methods after all of them are initialized
mfranz [Sat, 11 Jun 2005 09:13:44 +0000 (09:13 +0000)]
call the subsystems' postinit() methods after all of them are initialized

19 years agoA few fixes from David Culp.
ehofman [Sat, 11 Jun 2005 08:19:16 +0000 (08:19 +0000)]
A few fixes from David Culp.

19 years agoFix by Durk Talsma to fix the Airport AI directory preread code.
ehofman [Sat, 11 Jun 2005 08:13:30 +0000 (08:13 +0000)]
Fix by Durk Talsma to fix the Airport AI directory preread code.

19 years agoDavid Culp:
ehofman [Sat, 4 Jun 2005 09:38:52 +0000 (09:38 +0000)]
David Culp:

I added an AIStatic object to my OV-10 sim for use in putting city signs,
vehicles, or anything else that will be static, but that I don't want to put
in the scenery files.  It's inexpensive.  Before, I was making such things
from AIShip.

I also added the ability to set flight plans to repeat, so that when an
airplane reaches the end it just starts over at the beginning.  This is
useful for my OV-10 sim.  I have C-141 and KC-135 traffic flying approaches
to Ramstein, and I only have to define two AI objects to do this.

Also, I found an inefficiency in AIBase, where every AI object was calculating
Mach number at every dt.  Now only AIBallistic objects do this.

19 years agoFix some more of my own stupidity.
curt [Fri, 3 Jun 2005 15:25:19 +0000 (15:25 +0000)]
Fix some more of my own stupidity.

19 years agoFix some stupidity (mine).
curt [Fri, 3 Jun 2005 15:23:10 +0000 (15:23 +0000)]
Fix some stupidity (mine).

19 years agoI had hoped that gmtime's lack of thread-safety wouldn't bite us. It does.
mfranz [Fri, 3 Jun 2005 08:39:50 +0000 (08:39 +0000)]
I had hoped that gmtime's lack of thread-safety wouldn't bite us. It does.
Fix jumping clock hands.

19 years agoMathias Fröhlich:
ehofman [Thu, 2 Jun 2005 08:51:47 +0000 (08:51 +0000)]
Mathias Fröhlich:

this is basically the past patch I sent to the list and which should now
really (...!?!?) fix the no ground below aircraft problem.
Reasons:
I understood my remaining thinko I introduced with the prevous patch, and the
same thinko I made in my test cases.
The feedback from the list told me that it should help.

19 years agoMathias Fröhlich:
ehofman [Mon, 30 May 2005 08:48:27 +0000 (08:48 +0000)]
Mathias Fröhlich:

2.
I made YASim query the the ground cache at the wrong place. This one fixed
this, one can now land the bo105 on top of the oracle buildings  :)

3.
Is a followup of the scenery center update code: Register the scenery center
transform at the time it is put into the scene graph not at creation time.

4.
I held that part back from the past hitlist patch, because I hoped that it
will be sufficient (and the last one was in fact the biggest part) without.
As some test cases from Melchior showed me, it is not. We have additionally
to the wrong computed transform from the prevous patch some roundoff
problems. This patch adds some small tolerance to for the point in triangle
test.
... may be one even needs to increase the eps value further if starting at
some tile boundaries still fails.

5.
That is a big chunk.
Tested now for two days while hunting the second patch  :) .
That is a partial rewrite of the groundcache to use its own datastructures for
that flat scenegraph in the cache. The basic advantage is, what Erik
suggested, to precompute some often used values of these triangles. Also
allmost all computations are now in double precision which should decrease
(hopefully fix), together with a similar tolerance for some point in triangle
tests, the problems with 'no ground below aircraft'.
I am playing with octrees for the groundcache, that will finally solve the
performance problem when high triangular count models end up in the
groundcache. This patch is also some prework for those octrees ...

19 years agoSome small fixes and security updates.
ehofman [Mon, 30 May 2005 08:47:00 +0000 (08:47 +0000)]
Some small fixes and security updates.

19 years agoFix a number of build issues; Not all compilers support strnlen(), some platforms...
ehofman [Fri, 27 May 2005 18:49:45 +0000 (18:49 +0000)]
Fix a number of build issues; Not all compilers support strnlen(), some platforms use more than one lend-ending character and capture lines starting with a whitespace also.

19 years agoBe a tad more clever on readin the apt database; optimize the if statements a bit...
ehofman [Fri, 27 May 2005 17:46:35 +0000 (17:46 +0000)]
Be a tad more clever on readin the apt database; optimize the if statements a bit and dont tokenize strings we don't want to see anyhow.

19 years agoDon't try to open runway and parking files for every airport in the
andy [Fri, 27 May 2005 17:06:13 +0000 (17:06 +0000)]
Don't try to open runway and parking files for every airport in the
database.  Works fine on Linux, but is a huge performance hit (1
minute) on cygwin.  Keep a cache of actual directories and check that
first.

19 years agoA patch from Mathias to fix the startup at a tile boundry problem.
ehofman [Thu, 26 May 2005 08:13:06 +0000 (08:13 +0000)]
A patch from Mathias to fix the startup at a tile boundry problem.

19 years agoThe "catching up on tile delete queue" doesn't justify an ALERT message.
mfranz [Sun, 22 May 2005 17:14:15 +0000 (17:14 +0000)]
The "catching up on tile delete queue" doesn't justify an ALERT message.
It happens regularly during normal operation (ufo!) and only informs about
unfortunate, but known and deliberate behavior. The user can't do anything
about it, anyway. And finally: flooding the console with this message does
only *add* to fgfs' sluggish performance and makes every other message
go unnoticed.

19 years agoHarald JOHSNEN:
ehofman [Sun, 22 May 2005 08:08:22 +0000 (08:08 +0000)]
Harald JOHSNEN:

Changes
=======

- correct the transparency probleme when old 3d clouds were enabled
 (rendering context with an alpha channel)
- changed rain cone orientation, it can now be viewed from helicopter or chase
  view (still not tower view)
- clouds are a bit more yellow/red at dawn/dusk
- weather data is now correctly propagated to the interpolator, this correct
  visibility, wind, etc
- the 'metar' weather scenario now immedialty reuse the real metar data
- real metar no more overwrite custom weather scenario

19 years agoSync. w. JSBSim CVS.
ehofman [Sun, 22 May 2005 08:06:47 +0000 (08:06 +0000)]
Sync. w. JSBSim CVS.

19 years agoMSVC fix.
ehofman [Sun, 22 May 2005 07:36:26 +0000 (07:36 +0000)]
MSVC fix.

19 years agoAdded Farenheit temperature conversion to the property tree.
curt [Fri, 20 May 2005 19:42:53 +0000 (19:42 +0000)]
Added Farenheit temperature conversion to the property tree.

19 years agoRevert the previous patch.
ehofman [Tue, 17 May 2005 09:56:52 +0000 (09:56 +0000)]
Revert the previous patch.

19 years agoDavid Culp:
ehofman [Mon, 16 May 2005 09:48:00 +0000 (09:48 +0000)]
David Culp:

1)  The AIStorm sets the properties:
         /environment/turbulence/magnitude-norm
         /environment/turbulence/rate-hz

    The actual turbulence effects are handled by the FDM.
    If the effects are deemed unrealistic, then that will
    have to be fixed in the FDM(s).

2)  The zone of turbulence is cylindrical, and is centered
    at the AIStorm's lat/lon.  The diameter is set with
    <diameter-ft>, the top with <height-msl>, the bottom is
    assumed to be at <altitude> minus 1000 feet.

3)  Note that the zone of turbulence may not match well with
    the visual model of the storm.  In this case I had to
    x-offset the storm model by 4700 meters to match the zone
    of turbulence. (i.e. the storm model is 4700m off center).

4)  While I was in there I also increased the speed of the
    lightning flashes to look more realistic.

19 years agoOops, I didn't test compile the latest code and this is what happens.
ehofman [Mon, 16 May 2005 09:05:17 +0000 (09:05 +0000)]
Oops, I didn't test compile the latest code and this is what happens.

19 years agoMake the dialogs work again.
ehofman [Mon, 16 May 2005 08:37:18 +0000 (08:37 +0000)]
Make the dialogs work again.

19 years agoHarald JOHNSEN:
ehofman [Sun, 15 May 2005 09:26:17 +0000 (09:26 +0000)]
Harald JOHNSEN:

This is another update for the cloud code, a lot of lines but this time I have started to add the doxygen doc.

Misc
====

- corrected a bug when RTT is not available, the current rendering context was
  altered
- if RTT is not available then 3d clouds are not drawn at all
- impostors lighting is now recomputed when the sun changes position
- distant objects are no more seen in front of clouds
- blending of distant clouds is a bit better now
- litle optimization of code (uses a less cpu time)
- use layer wind speed and direction (no more hardcoded wind)
- fov is no more hardcoded

Changes
=======

- clouds (cu only) are dissipating/reforming (experimental)
- compute a turbulence factor that depends on surrounding clouds and type of
  clouds (experimental)
- clouds shapes are defined in cloudlayers.xml
- type of clouds present in a layer is also defined in cloudlayers.xml
- cloud layers are generated from metar and other misc. data (in progress)
- added a rain effect around the viewer (enabled in the rendering dialog and
  when the metar property says so)
- added a lightning effect (enabled in the rendering dialog) : cb clouds spawn
  new lightnings
- added a dialog to select from different weather source : metar/property,
  a 'fair weather' environment and a 'thunderstorm' environment.

19 years agodo also silence the marker sounds on --disable-sound
mfranz [Thu, 12 May 2005 18:30:59 +0000 (18:30 +0000)]
do also silence the marker sounds on --disable-sound

19 years agocurrently "tailwheel-lock=true" means 'unlocked', which is
mfranz [Tue, 10 May 2005 10:56:55 +0000 (10:56 +0000)]
currently "tailwheel-lock=true" means 'unlocked', which is
confusing and inconsistent with brake properties (where 1.0
means (b)locked) ==> reverse tailwheel-lock meaning

19 years agodon't use /sim/ATC/ and /sim/atc/ wildly mixed together; it's only /sim/atc/
mfranz [Tue, 10 May 2005 09:44:13 +0000 (09:44 +0000)]
don't use /sim/ATC/ and /sim/atc/ wildly mixed together; it's only /sim/atc/
now, just as it was everywhere in ATC/ATCDialog.cxx already

19 years agothere's no such thing as /sim/time/elapsed-ms --> elapsed-sec
mfranz [Tue, 10 May 2005 09:29:24 +0000 (09:29 +0000)]
there's no such thing as /sim/time/elapsed-ms  --> elapsed-sec

19 years agoSimon Hollier:
mfranz [Tue, 10 May 2005 06:26:59 +0000 (06:26 +0000)]
Simon Hollier:
don't crash when using --disable-splash-screen and/or if font can't be found

19 years agothe plib documentation says we should call fntInit() before using fonts;
mfranz [Sun, 8 May 2005 14:32:56 +0000 (14:32 +0000)]
the plib documentation says we should call fntInit() before using fonts;
not that it makes a difference ...

19 years agoSolaris fixes
ehofman [Sat, 7 May 2005 08:56:42 +0000 (08:56 +0000)]
Solaris fixes

19 years agofade out text, too; cosmetics
mfranz [Fri, 6 May 2005 15:48:48 +0000 (15:48 +0000)]
fade out text, too; cosmetics

19 years agoAdd support for altering the border thickness of objects and add a 'frame' object...
ehofman [Fri, 6 May 2005 11:46:52 +0000 (11:46 +0000)]
Add support for altering the border thickness of objects and add a 'frame' object as a visual representation of a group.

19 years agonavigation data alone doesn't take *that* long ...
mfranz [Fri, 6 May 2005 09:47:46 +0000 (09:47 +0000)]
navigation data alone doesn't take *that* long ...

19 years agofix wording
mfranz [Fri, 6 May 2005 09:16:30 +0000 (09:16 +0000)]
fix wording

19 years ago- implement progress information (enabled by default; can be turned off via
mfranz [Fri, 6 May 2005 09:08:44 +0000 (09:08 +0000)]
- implement progress information (enabled by default; can be turned off via
  /sim/startup/splash-progress)
- a string in /sim/startup/splash-title is displayed on top of the screen
  and by default empty
- the splash image is scaled down if 512x512 is too big
- code cleanup

19 years agoremove redundant check
mfranz [Wed, 4 May 2005 21:31:16 +0000 (21:31 +0000)]
remove redundant check

19 years ago- open window as soon as possible
mfranz [Wed, 4 May 2005 21:28:42 +0000 (21:28 +0000)]
- open window as soon as possible
- move most of the initialization in chunks into the idle loop
- remove unused first fgSplashUpdate() parameter

19 years agoone dialog-show is enough
mfranz [Wed, 4 May 2005 21:25:57 +0000 (21:25 +0000)]
one dialog-show is enough

19 years agoOops, forgot to update the network byte order conversion functions when I
curt [Wed, 4 May 2005 21:07:03 +0000 (21:07 +0000)]
Oops, forgot to update the network byte order conversion functions when I
updated the structures.

19 years agoreverting last patch: the (non)redrawing problems are simply too annoying :-(
mfranz [Wed, 4 May 2005 12:11:37 +0000 (12:11 +0000)]
reverting last patch: the (non)redrawing problems are simply too annoying :-(

19 years agoopen black window immediately. This doesn't only give useful feedback,
mfranz [Wed, 4 May 2005 10:57:35 +0000 (10:57 +0000)]
open black window immediately. This doesn't only give useful feedback,
it also allows to switch desktops shortly after starting fgfs without
having the window pop up on the "wrong" virtual desktop.

19 years ago32 bit integers are somewhat magical and handled pretty well across platforms
curt [Tue, 3 May 2005 20:34:21 +0000 (20:34 +0000)]
32 bit integers are somewhat magical and handled pretty well across platforms
in terms of predictable packing and byte ordering.  So rather than trying to
get fancy and shave a few bits off the structure sizes, just go with 32 bit
ints for everthing which saves a lot of potential headaches in the cross
platform and cross architecture arenas.

19 years agoDescribe the font tag
ehofman [Tue, 3 May 2005 12:50:20 +0000 (12:50 +0000)]
Describe the font tag

19 years agoFix a couple of stupid mistakes, I'm off to find a brown paper bag now.
ehofman [Tue, 3 May 2005 12:48:31 +0000 (12:48 +0000)]
Fix a couple of stupid mistakes, I'm off to find a brown paper bag now.

19 years agoShoot, I removed a bit of crucial information just before committing it.
ehofman [Tue, 3 May 2005 12:20:17 +0000 (12:20 +0000)]
Shoot, I removed a bit of crucial information just before committing it.

19 years agoMake it possible to define a different font for the labels
ehofman [Tue, 3 May 2005 11:58:33 +0000 (11:58 +0000)]
Make it possible to define a different font for the labels

19 years agoUpdates.
ehofman [Mon, 2 May 2005 17:03:04 +0000 (17:03 +0000)]
Updates.

19 years agoAllow for defining the label color.
ehofman [Mon, 2 May 2005 14:45:04 +0000 (14:45 +0000)]
Allow for defining the label color.

19 years agoAdd lightning support from David Culp.
ehofman [Mon, 2 May 2005 12:29:13 +0000 (12:29 +0000)]
Add lightning support from David Culp.

19 years agoMake it optional whether a dialog can be dragged or not.
ehofman [Mon, 2 May 2005 12:14:12 +0000 (12:14 +0000)]
Make it optional whether a dialog can be dragged or not.

19 years agocleanup (deleting NULL pointers is explicitly allowed)
mfranz [Mon, 2 May 2005 06:03:25 +0000 (06:03 +0000)]
cleanup (deleting NULL pointers is explicitly allowed)

19 years agodon't crash if fgfs is called with an invalid argument to the --vor option
mfranz [Sun, 1 May 2005 14:27:06 +0000 (14:27 +0000)]
don't crash if fgfs is called with an invalid argument to the --vor option

19 years agoMathias:
ehofman [Fri, 29 Apr 2005 14:38:24 +0000 (14:38 +0000)]
Mathias:

I have done a patch to eliminate the jitter of 3D-objects near the viewpoint
(for example 3D cockpit objects).
The problem is the roundoff accuracy of the float values used in the
scenegraph together with the transforms of the eyepoint relative to the
scenery center.

The solution will be to move the scenery center near the view point.
This way floats relative accuracy is enough to show a stable picture.

To get that right I have introduced a transform node for the scenegraph which
is responsible for that shift and uses double values as long as possible.
The scenery subsystem now has a list of all those transforms required to place
objects in the world and will tell all those transforms that the scenery
center has changed when the set_scenery_center() of the scenery subsystem is
called.
The problem was not solvable by SGModelPlacement and SGLocation, since not all
objects, especially the scenery, are placed using these classes.

The first approach was to have the scenery center exactly at the eyepoint.
This works well for the cockpit.
But then the ground jitters a bit below the aircraft. With our default views
you can't see that, but that F-18 has a camera view below the left engine
intake with the nose gear and the ground in its field of view, here I could
see that.
Having the scenery center constant will still have this roundoff problems, but
like it is now too, the roundoff error here is exactly the same in each
frame, so you will not notice any jitter.

The real solution is now to keep the scenery center constant as long as it is
in a ball of 30m radius around the view point. If the scenery center is
outside this ball, just put it at the view point.

As a sideeffect of now beeing able to switch the scenery center in the whole
scenegraph with one function call, I was able to remove a one half of a
problem when switching views, where the scenery center was far off for one or
two frames past switching from one view to the next. Also included is a fix
to the other half of this problem, where the view position was not yet copied
into a view when it is switched (at least under glut). This was responsible
for the 'Error: ...' messages of the cloud subsystem when views were
switched.

19 years agoSame bug, different place. Don't treat a length of zero as "please
andy [Tue, 26 Apr 2005 20:57:06 +0000 (20:57 +0000)]
Same bug, different place.  Don't treat a length of zero as "please
strlen() it", because real files and properties can have lengths of
zero.

19 years agoDon't try to strlen() the input buffer if the length is zero. That
andy [Tue, 26 Apr 2005 17:18:00 +0000 (17:18 +0000)]
Don't try to strlen() the input buffer if the length is zero.  That
was probably my idea of a feature, but if the input buffer actually
does has a length of zero (as Melchior discovered for the case of a
zero-length .nas file) then there will be no null.

19 years agoHarald Johnson:
ehofman [Tue, 26 Apr 2005 08:31:25 +0000 (08:31 +0000)]
Harald Johnson:

Changes
=======

- corrected some strange behavior when playing with the render dialog options
- the density slider is now working : if you are fps limited and still want to see clouds in
  the distance you should play with that
- added the choice for texture resolution, its more comprehensible now (before it was
  wrongly allways choosing 64x64 textures)
- changed the initial texture size : you now have 64 texture of 64x64, this uses 1Mo of
  texture memory (before it was 20 texture of  256x256, that took more memory and there was
  not enought impostors)
- sun vector is now right so the lighting is a bit better
- removed useless sort and light computations for impostors, this should save a lot of cpu
- blending of distant cloud is more accurate now
- clouds are now positioned correctly, they don't try to escape you anymore
- no more red/white boxes around cloud
- textures are now filtered (no more big pixels)

known bugs
==========

- distant objects are seen in front of clouds

19 years agoHarald Johnson:
ehofman [Sun, 24 Apr 2005 11:17:23 +0000 (11:17 +0000)]
Harald Johnson:

- new and updated sources for the new volumetric clouds
- 2 new textures for the clouds
- an update to the render dialog to enable/disable and change a few parameters
  for the new clouds

19 years agocode simplification: use atan2() [discussed with David]
mfranz [Fri, 22 Apr 2005 06:41:07 +0000 (06:41 +0000)]
code simplification: use atan2()    [discussed with David]

19 years ago"condition" needs to be clamped like "mixture", so that it is settable via
mfranz [Thu, 21 Apr 2005 14:17:59 +0000 (14:17 +0000)]
"condition" needs to be clamped like "mixture", so that it is settable via
controls.adjEngControl()  (this is necessary to make the b1900d's condition
settable via m/M keys or the joystick's configure mixture bindings)

19 years agoMathias Fröhlich:
ehofman [Tue, 19 Apr 2005 13:21:43 +0000 (13:21 +0000)]
Mathias Fröhlich:

I have some small updates to the ground cache.

- Remove the usage of dynamic_cast where it is known that the result will be
  non null.
- Renormalize the surface normal in double precision.
- Place the groundcaches center at the point it was requested not at the
  scenery center. This fixes the problems with JSBSim's trimming together with
  the ground cache. Now I am ready to commit JSBSim's ground cache usage.

19 years agoMelchior: Make line wrapping in textboxes configurable, and enable it by default
ehofman [Tue, 19 Apr 2005 13:15:04 +0000 (13:15 +0000)]
Melchior: Make line wrapping in textboxes configurable, and enable it by default

19 years agoDavid Culp:
ehofman [Tue, 19 Apr 2005 12:52:26 +0000 (12:52 +0000)]
David Culp:

I'm looking through the AI code, trying to find the bug that's killing the
thermals.  The following things don't look right:

1)  AIManager::101  ,   the Traffic Manager pointer is searched for by name at
every dt.   I'll leave this for you to look at.

2)  AIManager::295  ,  the thermal height is not being set.  We need to
restore the line:         ai_thermal->setHeight(entity->height_msl);
This fixes the thermal problem.

3)  AIManager::328  ,  I changed the fetching of the user state to occur every
sim cycle, and changed the fetching function from by-name lookup to a lookup
by node pointer.  It should be faster now, and more accurate too.  This helps
the air-refueling.

19 years agoMelchior FRANZ:
ehofman [Tue, 19 Apr 2005 12:34:38 +0000 (12:34 +0000)]
Melchior FRANZ:

There weren't changes to this script in a while -- it almost looks
like dead code, but isn't. I'm using this regularly. valgrind works
better than ever (version 3.0 coming out soon, and the alpha already
very usable). New address: http://www.valgrind.org/

19 years agoThis is a work in progress. I am extending the "ExternalPipe" protocol to
curt [Tue, 19 Apr 2005 01:44:56 +0000 (01:44 +0000)]
This is a work in progress.  I am extending the "ExternalPipe" protocol to
have a "property" mode as well as the original "binary" mode.  The property mode
will allow the remote module to request any set of properties, and it will send
those properties each frame.  The remote module can reply with a list of arbitrary
property name/value pairs to update on the FlightGear side.

This is a first stab, so it's not the cleanest, most well concieved code, but it
allows an external module (communicating via a pipe) to have a huge amount of
flexibility in the data in can access and update.

19 years agoFix a couple typos.
curt [Tue, 19 Apr 2005 01:41:17 +0000 (01:41 +0000)]
Fix a couple typos.

19 years agoUpgrade to Nasal 1.0 test candidate
andy [Mon, 18 Apr 2005 19:49:13 +0000 (19:49 +0000)]
Upgrade to Nasal 1.0 test candidate

19 years agoFix units bug with fuel flow
andy [Wed, 13 Apr 2005 19:42:29 +0000 (19:42 +0000)]
Fix units bug with fuel flow

19 years agoAdd the color description.
ehofman [Wed, 13 Apr 2005 11:42:49 +0000 (11:42 +0000)]
Add the color description.

19 years agoAllow for recolloring the dialogs.
ehofman [Wed, 13 Apr 2005 11:39:53 +0000 (11:39 +0000)]
Allow for recolloring the dialogs.

19 years agoDon't overwrite the castering value with the non-castering one. Also,
andy [Fri, 8 Apr 2005 22:39:46 +0000 (22:39 +0000)]
Don't overwrite the castering value with the non-castering one.  Also,
make the caster-angle-deg a synonym for the steering angle when the
wheel is non-castering.

19 years agoOops, stray line in the checkin. I'm sure fenv.h would have broken on
andy [Fri, 8 Apr 2005 20:55:02 +0000 (20:55 +0000)]
Oops, stray line in the checkin.  I'm sure fenv.h would have broken on
at least one system...

19 years agoExport "rollspeed-ms" and "caster-angle-deg" properties for gear
andy [Fri, 8 Apr 2005 20:46:43 +0000 (20:46 +0000)]
Export "rollspeed-ms" and "caster-angle-deg" properties for gear
objects.  Josh Babcock wanted these for the B-29 model so he can
properly animate the gear.

19 years agoMelchior FRANZ:
ehofman [Wed, 6 Apr 2005 08:46:39 +0000 (08:46 +0000)]
Melchior FRANZ:

Make SDL window resizable; This exposes the same problem that many
GLUT users have: resizing up may cause a temporary switch to software
rendering if the card is low on memory. Resizing down again switches
back to HW rendering. (KSFO is texture intensive, but there are no
problems in LOWL, and elsewhere.) Less and less users will have the
problem as cards become better, and it's no reason not to allow
resizing altogether.

19 years agoMelchior FRANZ:
ehofman [Wed, 6 Apr 2005 08:24:30 +0000 (08:24 +0000)]
Melchior FRANZ:

_course_deg is first initialized in the if()-branch (gps.cxx:419). But
this branch isn't entered at first run if wp0==wp1, so that in line 615
fgfs tries to SG_NORMALIZE_RANGE() a random value, which can take a
long while if the number huge. This was occasionally a number greater
than 10160!

- initialize all vars before they are used (fixes endless loop)
- fix some compiler warnings (initialization order, unused vars)

19 years agoMelchior FRANZ:
ehofman [Thu, 31 Mar 2005 17:00:27 +0000 (17:00 +0000)]
Melchior FRANZ:

FGAIMgr::GenerateSimpleAirportTraffic() tries to determine the airport's local
hour from the /sim/time/gmt-time string, which fails, because at this time the
property is still empty. That's why I don't get ATIS at LOWG (where it is *not*
midnight right now.  :-)    -> use sg's get_cur_time() instead

19 years agoMelchior FRANZ:
ehofman [Thu, 31 Mar 2005 08:54:04 +0000 (08:54 +0000)]
Melchior FRANZ:

- don't treat *every* child in the xml as submodel, especially not a "param"
  block
- do not only *enable* the contrail flag above some altitude, but also
  disable it below

19 years agoCygwin (windows) fix.
ehofman [Thu, 31 Mar 2005 08:41:41 +0000 (08:41 +0000)]
Cygwin (windows) fix.

19 years agoMelchior FRANZ:
ehofman [Tue, 29 Mar 2005 08:35:13 +0000 (08:35 +0000)]
Melchior FRANZ:

showDialog() is careful not to create a new FGDialog() if a dialog with the
same name is already open (active). But at this point it is already too late:
newDialog(), which was called shortly before, has already overwritten the
dialog properties. This leads to animated garbage in the best case, and a
segfault in format_callback() in the worst case.

- GUI::newDialog(): Don't you overwrite properties of an active dialog!
- GUI::readDir(): You may do that, but delete the old dialog first!
  (necessary for reloading the GUI)

- FGDialog::makeObject(): only set format_callback() with setRenderCallback()
  if the property is "live". Otherwise, only call it once at construction
  time. This isn't only a performance improvement. Without this the label
  was growing until it hit the limit (256).

19 years agoMelchior FRANZ:
ehofman [Sat, 26 Mar 2005 10:45:00 +0000 (10:45 +0000)]
Melchior FRANZ:

The previous message wasn't totally correct. Strings are now allowed, too. And
the pattern is now '[ -+#]?\d*(\.\d*)?l?[fs]' and *may* be embedded in a string.
There may only be one %s or %f, though. %% is allowed in the preamble/postamble.
(Yes, %ls is allowed, too, and treated as %s.)

Also, "end" is superfluous now.

19 years agoMelchior FRANZ:
ehofman [Sat, 26 Mar 2005 10:09:34 +0000 (10:09 +0000)]
Melchior FRANZ:

Printing floats in dialogs with 8 digits after the comma is inappropriate
for most cases.

- implement a "format" property for "text" gui elements (a.k.a. pui label).
  Number formats are set by strtod/snprintf, while formats on non-numbers
  are replaced by "%s". Practical example in the upcoming material.nas update.
  Valid formats regex:  '%[ -]?\d*(\.\d*)?l?f' (IOW: the format must begin
  with '%' and end with 'f').

  # Nasal:
  number = dialog.addChild("text");
  number.set("label", "3.1415926");
  number.set("format", "%.3f");

19 years agoMipsPRO needs -c99 for int16_t types.
ehofman [Sat, 26 Mar 2005 10:08:32 +0000 (10:08 +0000)]
MipsPRO needs -c99 for int16_t types.

19 years agoUpdate nasal function name.
curt [Fri, 25 Mar 2005 01:37:58 +0000 (01:37 +0000)]
Update nasal function name.