ThorstenB [Sat, 4 Jun 2011 15:55:12 +0000 (17:55 +0200)]
Fix crash when display/screen number invalid
getScreenResolution shouldn't be called before the safety check.
Fixes commit ba7d8b8155731c95acf43f5e5a5a007cc6e96cdc
Torsten Dreyer [Fri, 3 Jun 2011 20:05:43 +0000 (22:05 +0200)]
Fix bug#333 2D clouds sometimes not visible with material shaders are disabled
Only draw 3d clouds if enabled and shader-effects are true.
Remove the property-tie for 3dclouds-enabled and use a change listener
instead which also listens for changes of the shader-effects property.
ThorstenB [Wed, 1 Jun 2011 19:31:48 +0000 (21:31 +0200)]
Ensure window position is 0,0 for multi-display setups with fullscreen mode
Fix an issue introduced by commit 863551a932e21f3d4315c0ceb51005929acc9f20
for multi-display setups.
Some code clean-up.
Torsten Dreyer [Tue, 31 May 2011 13:28:32 +0000 (15:28 +0200)]
Compute gravitational acceleration
Compute gravitational acceleration based on the formula of
Somigliana corrected for altitude and provide the value
in property /environment/gravitational-acceleration-mps2
ThorstenB [Sat, 28 May 2011 22:05:33 +0000 (00:05 +0200)]
Bertrand Coconnier: bug fix for #184, JSBSim: command line arguments
1. The atmospheric properties of FG are not yet initialized when
JSBSim is initialized.
-> patch is quite basic and there may exist smarter ways to initialize
properly the environment before the FDM.
2. The Euler angles were initialized after the velocities.
3. The glide slope and rate of climb were ignored. Fixes all FDMs (YASim,
UIUC, JSBSim, etc.)
4. Some properties were instructed to re-use their previous value while
they should not.
5. Some bugs existed in JSBSim trim code. -> This bug has already been
fixed in JSBSim but the corresponding patch has not yet been applied to FG.
ThorstenB [Sat, 28 May 2011 21:27:46 +0000 (23:27 +0200)]
issue #127: make screen shots work with OSG multi-threading
Make sure actual snap shot is executed in graphics context.
(patch requires simgear+fgdata update!)
James Turner [Sat, 28 May 2011 20:20:06 +0000 (21:20 +0100)]
Fix yet another subtle resize problem I introduced, which upset PUI. This code is terribly fragile - yuck. Thanks to papillion 81 for tracking down the issue,
ThorstenB [Sun, 22 May 2011 20:56:51 +0000 (22:56 +0200)]
#323: Bad init sequence could segfault
Oops, early window event callbacks could trigger issues on some systems.
Fixes an issue caused by my commit 473d1447c330780ecac8a12a2d0b35c4eebdde41
ThorstenB [Sun, 22 May 2011 16:18:39 +0000 (18:18 +0200)]
Bugfix for #106: main view port aspect-ratio broken when 2D panels are moved
Seems the hack was necessary for the pre-OSG display only. Or the feature
is broken since OSG port altogether. But it caused issues for 3D and 2D
cockpits when /sim/virtual-cockpit wasn't enabled. => Removing for now.
ThorstenB [Sun, 22 May 2011 09:02:15 +0000 (11:02 +0200)]
Fix #109: Seg faults caused by wxradar with ARC display mode (aerostar700)
Fixes an ugly issue with OSG overwriting memory/stack. wxradar triggered
the issue in display mode "ARC" - since it configured a display mask (12
vertices) but all vertices were immediately removed again ("_vertices->clear()").
Issue is fixed, mask now working - however the mask wasn't even properly
aligned for the display (probably never worked since OSG port). The display
mask is only really required for weather display - so disabling for now.
ThorstenB [Sat, 21 May 2011 11:27:09 +0000 (13:27 +0200)]
New "pause" fgcommand.
Original property-rules in keyboard.xml toggled master and clock freeze
independently - which caused issues when only one property was true. New
command toggles both properties consistently.
See #316: Caused issues with sky becoming black in dense fog.
Also: when the fog issue is solved, we could configure the constant
(black) clear color once only (during init), no need to do it in every
loop. Also, entire "if (skyblend) { ... } else {..}" was redundant,
since "if" and "else" clauses were all identical - and the "clearColor"
variables were unused. => Once the fog issue is solved, we can easily
improve the clearColor configuration here.
ThorstenB [Fri, 20 May 2011 17:48:05 +0000 (19:48 +0200)]
issue #316: panning not working when center-on-aircraft enabled
Panning feature looked broken to some users since auto-center is enabled
by default which blocks panning. center-on-aircraft is now disabled
automatically when view is panned.
Torsten Dreyer [Fri, 6 May 2011 12:12:17 +0000 (14:12 +0200)]
Remove unused class SGEnviro
This class and their source files visual_enviro.[h|c]xx were
unused since OSG transition. It's only functionality was to
keep a variable for the enable-state of rendering of precipitation.
This has now been moved to SGPrecipitation.
This patch also removes all references to this class and
visual_enviro.hxx. Wxradar needs a new implementation for cloud
echoes which probably should be part of fgclouds.
Curtis L. Olson [Thu, 5 May 2011 19:13:18 +0000 (14:13 -0500)]
Fix a problem with the YASim turbulence model. This change has been
coordinated with and approved by Andy.
The lattice(x,y) arguments were being "WRAP()'d" but the WRAP() function
didn't make sense. Instead it was forcing the value to zero if it was
greater than the wrap limit. This was creating large areas of constant
values in the perlin noise maps which resulted in a "constant" turbulence
vector over time -- which is just weird.
Andy couldn't see any reason why the values should be wrapped and couldn't
remember any reason why the WRAP() function was set up like it was.
Andy wanted me to make sure and mention that he was INSANE when he wrote that
code (but now he's sane ... err, mostly.)
ThorstenB [Wed, 4 May 2011 19:34:15 +0000 (21:34 +0200)]
#310: c++ header dependency
Header's dependency is to <cstring> not <memory>. <memory> itself had
dependency to <cstring> for earlier GCC version though.
Curtis L. Olson [Tue, 3 May 2011 16:12:55 +0000 (11:12 -0500)]
Bruce Hellstrom @ ATC Flight Sim.
New module contributed: AV400WSim.
Supports communication with external (aka real) Garmin 400/500 WAAS flight
sim units. Includes changes to options.cxx and fg_io.cxx to support
invoking and configuring the new module.