1
0
Fork 0
Commit graph

398 commits

Author SHA1 Message Date
James Turner
b1ff365a8f Make FGTaxiNode and FGParking inherit FGPositioned.
In preparation for caching the groundnet in the NavCache, make taxi-nodes and parkings inherit from FGPositioned. As part of this, make them heap (as opposed to value) classes, disable their copy-constructors, remove many mutating operations, and give them real constructors.
2012-09-25 00:31:17 +01:00
ThorstenB
2003e7cf2a Avoid compiler warning. 2012-09-21 15:36:52 +02:00
James Turner
6e7ac46751 Cached joystick config loading.
Avoid parsing all the joystick configs every launch.
2012-09-21 10:17:16 +01:00
James Turner
32248bf576 Support string-list properties in the cache.
Not used yet, but will aid in caching joystick and dialog configs.
2012-09-19 18:15:49 +01:00
James Turner
50c61b4211 Allow use of the system's SQLite3 library.
Keep distro packagers happy by having the option to use the system's sqlite library instead of our bundled version. Set SYSTEM_SQLITE=1 when running cmake to use the system one.
2012-09-19 14:28:25 +01:00
James Turner
9b900e9430 Implement a persistent cache for navigation data.
Cache the parsed navigation and airport data in a binary file to reduce
startup times and memory consumption (since only referenced FGPositioned
elements are held in memory).

Data will be reimported when the mod-time of any input file is changed.
If a global file is changed (nav.dat, awy.dat, apt.dat, etc), the cache
will be completely rebuilt, which takes approximately 30 seconds on
moderate hardware. (Future work may reduce this).
2012-09-19 11:38:19 +01:00
Stuart Buchanan
60af52707c Reduce severity of a failure to create a marker beacon due to an unknown runway from ALERT to WARN. Not particularly relevant error message for most users. 2012-06-30 20:50:57 +01:00
James Turner
20071b66af Fix an edge case in flight-plan inserts.
When inserting with an invalid index, ensure we return the leg based on the fixed-up index, not the original one. Thanks to Matthias Götz for the catch!
2012-06-26 15:16:03 +01:00
ThorstenB
aabea95d19 #769: fix glideslope reception
The glideslope station was only searched once whenever the NAV station
changed. However, sometimes a mismatching G/S station is found, since
another G/S station is still closer when the NAV station changes.
When this happened, the G/S station was never updated again (while the
NAV station stayed in range), resulting in the NAV receiver providing
correct localizer, but bad G/S data (data matching another, remote station).
Issue is fixed by alternating between searching NAV and G/S stations.
2012-06-18 22:57:22 +02:00
James Turner
1ef77b2bc2 More route-manager functionality moved to Nasal.
The routing behaviour now happens entirely in Nasal,
using a delegate, and can be over-ridden or disable
by aircraft authors. Default behaviour should be
unchanged.
2012-05-15 17:53:30 +01:00
James Turner
ce92730ef6 Expose FlightPlan delegates to Nasal, finally.
This will permit Nasal (e.g., FMS) to update nicely when the FlightPlan
is modified from anywhere else.
2012-05-12 17:23:17 +01:00
James Turner
0f61108f5b Break FlightPlan out into its own file. 2012-05-12 10:25:56 +01:00
James Turner
b0384d035f Remove remaining includes of simgear/waypoint 2012-05-11 23:49:12 +01:00
James Turner
acd8fa25e6 Expose procedure routing and fixes to Nasal. 2012-05-11 17:07:56 +01:00
James Turner
5808ed1b62 Permit an invalid index to be set on a flight-plan. 2012-05-07 10:59:34 +01:00
James Turner
1b7b69b498 Create a real FlightPlan (and Leg) class
Convert the route-manager to use a flight-plan internally, and expose
flightplan, leg and procedure data to Nasal. Move the Level-D parser
into its own file.
2012-05-07 00:35:48 +01:00
Frederic Bouvier
75fc136931 Remove redundant inclusion of math/SGMath.hxx 2012-05-05 11:20:04 +02:00
ThorstenB
0f462d4a6e Fix rpmlint/Linux packager complaints
about outdated/invalid FSF address in some license headers.
2012-05-05 01:42:41 +02:00
James Turner
ea73373109 Support PBD waypoints in procedures files.
http://code.google.com/p/flightgear-bugs/issues/detail?id=635
2012-05-02 22:09:41 +01:00
James Turner
2d267a5782 Remove PositionedBinding (which no one ever used), Nasal is better for this jobs. 2012-04-26 00:37:47 +01:00
James Turner
fb66aeade1 More search functions exposed to Nasal, also airport parking. 2012-04-24 22:12:56 +01:00
James Turner
3d46809ea8 Expose waypoint source (airport/runway/navaid) to Nasal 2012-04-24 10:53:46 +01:00
James Turner
a132ced084 Nasal airport functions for various ancillary data pieces now work. 2012-04-23 23:04:59 +01:00
ThorstenB
2f7f5da4ad marker beacon: catch NULL pointer
when runway not in navdb (affects incomplete/inconsistent nav data only).
2012-03-26 21:11:04 +02:00
Mathias Froehlich
8d3e1b06be Remove /sim/paths/use-custom-scenery-data.
Scenery people tell me that this is always set to true
today. Thus we can remove this property as this allows
me for some further osg loader cleanups.
2012-03-15 18:48:57 +01:00
Mathias Froehlich
c71c9aee0a Adapt to simgear SGMath change.
Simgears SGMath has lost its dependency on osg.
Update includes and code using these methods.
2012-03-03 13:37:43 +01:00
Frederic Bouvier
f1d0ac52a6 Fix MSVC9 build 2011-11-14 08:38:58 +01:00
James Turner
70b4f38ebc Goodbye automake. 2011-11-01 11:15:53 +00:00
James Turner
9bd4ba6eb0 Anchor flight gear::Waypt's destructor, and make it virtual. 2011-10-24 18:21:50 +01:00
James Turner
b1b4b7ecf4 Fix (nearly) all the std:: namespace violations in headers, in preparation for fixing SGsmplstat.hxx to *not* do a 'using namespace std'. 2011-10-17 17:41:59 +01:00
Torsten Dreyer
9f41ee414f Join duplicate fields ident and trans_ident in navrecord 2011-10-12 11:06:01 +02:00
James Turner
7abf7c5748 CMake header support for XCode/Visual Studio 2011-07-19 07:58:03 +01:00
Torsten Dreyer
c6d5b6ebdb Partial fix for #228: ambiguous navaid-names
This fixes at least the startup process.
If an ambigous fix name was presented with --vor=ID or --ndb=ID
present a list of matching records along with frequency and
position in the console to give the user the chance to pick
the correct one by adding the frequency with --vor-frequency=nnn.nn

It does not yes solve the issue when the user relocates using the
GUI dialog. This requires some GUI and Nasal hacking along with a
new Nasal helper function "navaidinfo".
2011-07-18 11:09:43 +02:00
Torsten Dreyer
eab9a65ebc Fix some gcc warnings 2011-07-17 19:31:28 +02:00
James Turner
029d2b00eb Tone down some log output for the release, especially related to airways/navaid loading. 2011-06-25 16:18:07 +01:00
James Turner
5572c53a7e Minor tweaks to positioned find commands. 2011-06-02 00:33:47 +01:00
James Turner
fc7e9740c3 Improvements to exposing FGPositioned via commands - support frequency searches. 2011-06-01 23:55:04 +01:00
ThorstenB
aeb4bc3672 Fix Linux build (automake)
CMake guys: please don't forget automake (yet)! ;-)
2011-06-01 21:01:50 +02:00
Frederic Bouvier
bff1f29fe8 Fix Linux build 2011-06-01 20:28:31 +02:00
Frederic Bouvier
f1a3cedb2f Fix win32 build 2011-06-01 20:25:53 +02:00
James Turner
2b967608a0 Expose FGPositioned data via property tree, and make comm-stations a real FGPositioned subclass. 2011-06-01 17:45:22 +01:00
ThorstenB
6cd0e5aac4 Merge remote branch 'origin/releases/2.2.0' into next 2011-02-19 12:00:43 +01:00
ThorstenB
118d8fbca5 #84: John Denker: Set correct file modes
Sources shouldn't be executable.
2011-02-19 11:55:43 +01:00
James Turner
d227258b3b Lazy caching of magvar on waypoints. Not used yet, but soon. 2011-01-20 08:49:09 +00:00
James Turner
7cbb3a10ed Expand route-manager waypoint info, to support smarter FMS functions. 2011-01-20 00:39:42 +00:00
James Turner
4b7ce32387 Remove some legacy declarations from navrecord 2011-01-03 21:47:24 +00:00
James Turner
0931fe332e Guard against NaN SGGeods in FGPositioned spatial queries, and in the GPS lat/lon reading code. 2010-12-19 16:18:12 +00:00
James Turner
a91ec5f9f9 Initial work on CMake build files, with considerable help from Olaf Flebbe. 2010-12-19 15:06:04 +00:00
Torsten Dreyer
58fbd0d72a msvc warning fixes 2010-12-15 16:40:25 +01:00
James Turner
d2bbaa69e0 Change how ils.xml data is loaded, to reduce impact on startup time. 2010-12-07 18:07:50 +00:00
James Turner
f7548fec1f Fix bug #185 - altitude ignored when adding waypoints to the route. 2010-12-01 23:57:01 +00:00
Christian Schmitt
0a5e86f4e6 remove old .cvsignore files 2010-11-11 01:16:29 +01:00
James Turner
f5c2c630eb Remove references to old (unused) airways code 2010-10-20 17:54:16 +01:00
James Turner
308fd1b112 Automake build fixes for airways commit. 2010-10-20 11:48:06 +01:00
James Turner
dd2eec7bd8 Airways/procedures code - add new data structures to store waypoints and
procedures, and routing algorithms, and modify the GPS, route manager and
WaypointList to use the new objects.
2010-10-20 09:02:02 +01:00
James Turner
8d5021f670 Make ident/name searches on FGPositioned case-insensitive (for the GPS, especially) 2010-08-14 20:24:30 +01:00
James Turner
57cb0a809b Fix bug 150 (airports not found in GPS search)
Overhaul and simplify the GPS search logic based
on experience and testing with the API. Also fix
search-by-name, which was broken.
2010-08-14 19:16:28 +01:00
James Turner
19360a8425 Fix 'using std::' abuses 2010-08-09 08:36:20 +01:00
Torsten Dreyer
2e6d7e111a gcc warning fixes 2010-06-26 21:24:46 +02:00
James Turner
45fbd8008d Support ICAO identifiers with more than four characters, in the AirportsList. 2010-05-09 11:11:52 +01:00
frohlich
1797f4cb3e Use methods from SGMath when possible.
Modified Files:
	src/Airports/apt_loader.cxx src/Navaids/positioned.cxx
	src/Navaids/positioned.hxx
2010-05-05 17:02:27 +02:00
jmt
e4c4a3a412 MapWidget for the GUI, initial commit. 2010-03-28 15:25:47 +02:00
Tim Moore
3836abcf4b Merge branches 'jmt/spatial', 'jmt/ref_ptr', 'jmt/navradio' and 'jmt/gps' 2010-01-12 00:09:19 +01:00
jmt
718d99f420 Fix for Martin: tolerate runway-associated navaids with a bogus ICAO/runway ident. 2009-12-20 08:39:33 +01:00
James Turner
0637cba24a Fix findNearest termination - ensure we expand all octree nodes that might contain closer results than the current list. 2009-12-19 23:13:17 +01:00
James Turner
34bbc6d974 Rewrite the spatial index to use a sparse octree on the cartesian coordinates of items.
* Fixes errors selecting 'nearest' items, including duplicates
* Stable behaviour around the poles and dateline
* Decently efficient, even for 'everything within 500nm' queries
2009-12-19 23:13:17 +01:00
jmt
c453d1a0cc Fix reset crash, thanks to Joe: make findNextWithPartial, and the route-manager, robust about people setting NULL / empty airport idents. 2009-12-12 00:11:34 +01:00
jmt
f11572cd64 Case insensitivity for findNextByPartialId. 2009-11-07 09:00:51 +01:00
jmt
ecfe4eb21b Check one potential source of the prime-meridian crash. 2009-11-04 23:12:59 +01:00
jmt
bc7ac3493e Refactor airway code to use SGGeod in external APIs. First of various changes to make airways more useful in GPS/FMS modules. 2009-10-08 10:37:21 +02:00
jmt
4b5518808b Use boost string algorithms to avoid dependence on C-library extensions missing in MSVC. Also they're just nicer. 2009-10-07 08:26:10 +02:00
jmt
2d5924939e Extend FGPositioned API to support queries by name as well as ident. 2009-10-06 07:29:03 +02:00
jmt
5c2dbb4239 Extender iterative search APIs with a 'has-next' return arg, to enable better iteration UI. 2009-10-06 07:28:38 +02:00
jmt
c08cc9693e Bugfix use of type checks in FGPositioned::findAllWithIdentSortedByRange 2009-10-04 02:04:18 +02:00
Tim Moore
9ebd19babf Use boost::to_lower_copy instead of function from simgear
The simgear function is about to get removed.
2009-10-01 00:15:37 +02:00
jmt
e1555ba9a5 Positioned support for adding user waypoints. 2009-09-30 08:13:09 +02:00
jmt
5755b7ae0e Further extensions to FGPositioned to support ongoing GPS work. 2009-09-29 00:01:56 +02:00
jmt
04b30f322d Extend FGPositioned to allow mapping from a string to a type. 2009-09-29 00:01:47 +02:00
Tim Moore
13ff5da4be Merge branch 'jmt/reciprocal' 2009-09-23 07:44:02 +02:00
jmt
29f84492a2 Different approach to handling the paired-ILS-on-opposite-runways situation. This uses additional information we now store (in FGRunway) to be more explicit about the behaviour (i.e only look at paired navids), and crucially, does not misbehave near either threshold. Instead it always switches about the runway midpoint (so back-course/missed-approaches are broken as before), leading to stable behaviour when touching down.
I am pretty confident this is (was, from FS2004) also the 'solution' taken by MSFS.
2009-09-17 22:51:44 +02:00
jmt
44bc440d32 Associate non-ILS localisers with their runway. 2009-09-17 22:51:44 +02:00
jmt
971e87bb49 Logging: less verbose about navaids we didn't align. 2009-09-17 22:45:30 +02:00
jmt
80e67b17c2 Set runway elevation to the airport elevation, and don't reset ILS/LOC elevation when aligning with runways. 2009-09-09 08:56:31 +02:00
jmt
25c55f67bf More precise matching of ILS records to navaids. 2009-09-03 00:02:48 +02:00
jmt
294a7b675a Add support for processing the ICAO.ils.xml scenery data into ILS/LOC nav records. 2009-09-03 00:02:48 +02:00
fredb
862f59aded Reserve a special FGPositionned type for pavements 2009-06-15 10:29:45 +02:00
jmt
21a8522160 Whoops, type codes for localizers and ILSs were swapped in the nav.dat reader 2009-06-15 10:29:44 +02:00
jmt
86d1e4ea9d Directly associate runways objects with their ILS navrecord (if one exists) 2009-06-15 10:29:44 +02:00
jmt
83c29b4f43 Fix a bad copy-and-paste bug in namedFindClosest, which broke things in the
multiple-matches case.
2009-06-11 16:05:21 +02:00
jmt
a29e5ce666 Remove some remaining non-route-related uses of SGWayPoint. 2009-06-11 16:05:20 +02:00
jmt
6e42458a55 Convert waypoint::CourseAndDistance users to use SGGeodesy helper functions. 2009-06-11 16:05:20 +02:00
jmt
031f9bb33b Dave Luff's patch to fix findNextWithPartialId 2009-06-11 16:05:19 +02:00
mfranz
b07ad149ae turn a few #include paths from the "foo" form to <foo>
The quotes form is normally only used for headers with path relative
to the including file's path, though the standard doesn't strictly
mandate this. This is consistent with the rest of sg/fg, it makes the
code's intent clearer and helps to find headers. (And it's a few
milliseconds faster, too.)
2009-05-18 12:24:17 +02:00
fredb
1d4aaa2f0d Compile with VS2005 in debug mode 2009-02-22 23:52:17 +01:00
jmt
9e945e3408 Fix Torsten's crash. A completely cross-platform issue, no idea why it didn't show up in local testing. 2009-01-10 00:07:44 +01:00
jmt
c9e8112a81 Add various helper filters, to make use of type-ranges, and reduce the need
to down-cast in filter implementations.
2009-01-10 00:07:01 +01:00
jmt
2d852024c6 Basic infrastructure to expose type ranges from filters, and hence reduce
how many candidates need to be submitted to the pass() hook.
2009-01-10 00:06:47 +01:00
jmt
e171f0ecdb Rename FGMarkerBeacon to FGMarkerBeacon record, to avoid a clash with the
instrument of the same name. In the future I'd prefer to rename the
instrument class instead (FGMarkerBeaconReciever?) but this is the safest
change for now.

Thanks (again) to Yon Uriarte for pointing out the problem (which seems to
affect MSVC more than gcc)
2009-01-07 10:33:02 +01:00
jmt
b0b6a0d998 Fix a bug resulting from my marker-beacon refactoring. Thanks to Yon Uriarte
for spotting the problem.
2009-01-07 10:27:18 +01:00
jmt
d756f913ec Refactor marker-beacons to be distinct from FGNavRecord. This is a big space
saving for beacons, but since they're surprisingly few (in nav.dat), not a
an enormous saving in real terms. The major motivation is that marker beacons
don't behave like other NavRecords for radio interaction - they have no ident,
frequency or range (in the sense that NavRecord means them).
2009-01-07 10:17:35 +01:00
jmt
f1b10eddfa FGAirportList is gone. Everything should work as before, especially the
AirportList dialog. (It would now be possible to trivially implement a
VOR or NDB named search, if anyone wants such a thing).
2008-12-27 13:20:08 +00:00
jmt
b58c8b6f19 Further work (still not enabled) on a fast + correct implementation of the
airportList search function. At least for me (with a mutex-based SGAtomic),
large vectors of referenced-pointers is a Bad Thing - copying on vector
resize is thrashing the locks.
2008-12-27 10:08:12 +00:00
jmt
660d59a098 Another clean-up iteration: FGAirportList::search is gone, replaced by two
static FGAirport helpers. As a result, another global index goes away. Use
the helpers to avoid ugly FGPositioned down-casts in various places.

Also converts the environment/METAR code to deal with FGAirport pointers,
instead of string identifiers, and contains work-in-progress code to implement
the AirportList dialog using FGPositioned. This isn't enabled yet for various
reasons, but is the final piece to allow FGAirportList to be removed.
2008-12-26 15:26:42 +00:00
jmt
988de9dbca Remove all name and spatial queries from FGNavList. All remaining queries are
by frequency (which makes sense), and use the FGPositioned spatial data if
required. As a result, the marker beacon list is gone (since beacons are only
searched spatially). In the process, clean up various minor things - most
notably, all the 'airport-related' navaids (ILS, GS, LOC, and the beacons) now
store a FGRunway* instead of an airport id string. This is more precise, and
saves string allocations.
2008-12-25 23:11:43 +00:00
jmt
7d5d756095 FGPositioned clean-ups - apply some desirable changes (such as making members
const) which were previously tricky but now easy. Make it possible not to
index certain types (used for taxiways) and exclude anonymous items from
the name index. Related to this, clean up FGRunway further - remove some public
members, and fix a dumb bug of mine, where we create reciprocal entries for
taxiways.

This should make startup (slightly) quicker, and shrinks FGRunway somewhat.
2008-12-24 14:48:30 +00:00
jmt
059f2e6a8e Convert the only remaining user of FGFixList to use an FGPositioned query,
and hence remove the query code from fix-list. The only remaining code deals
with parsing fix.dat.
2008-12-23 14:41:58 +00:00
fredb
e2bf85e67e James Turner : this patch
- updates how filtering is done on the various FGPositioned query functions - both spatial and ident-based.
- updates the KLN-89b / DCLGPS code to use FGPositioned for all Navaid/Airport queries.

me:
Add few include directives in globals.cxx to avoid such MSVC warning messages :
deletion of pointer to incomplete type 'FGAirportList'; no destructor called
deletion of pointer to incomplete type 'FGNavList'; no destructor called
deletion of pointer to incomplete type 'FGTACANList'; no destructor called
deletion of pointer to incomplete type 'FGFixList'; no destructor called
2008-12-09 07:58:46 +00:00
fredb
812485d623 James Turner : a trivial patch to remove a now obsolete default ctor from FGPositioned 2008-12-04 08:15:36 +00:00
fredb
f3b110e565 James Turner:
Attached patch updates the route-manager to use FGPositioned to search
for waypoints, instead of a manual airport / fix / navaid search. This
is good because it's now using the 'strictly closest' match, rather
than arbitrarily picking a distant fix over a nearby navaid. In my
case, the TLA VOR is significant to several EGPH procedures, but also
happens to be the ident of a fix a long, long way away.

Also updates the FGPositioned class to stop using Point3D, partly
because it's deprecated and partly because I had misunderstood the
interface and was using it wrong. For now, all FGPositioned distance
checks use SGGeodesy::inverse, which is accurate but inefficient. Once
FGPositioned queries are used for something on a hot path, I'll
probably store the cartesian position as well as the geodetic, to make
these checks fast.
2008-12-03 20:03:46 +00:00
ehofman
6bd7967e36 fix a typo 2008-09-13 09:20:47 +00:00
ehofman
bb2b03c7e3 James Turner:
Convert FGNavRecord to inherit FGPositioned. This is much more self-contained than the FGRunway change, since FGNavRecord already had good encapsulation of its state. However, it's a large diff due to moving around two nasty pieces of code - the 'align navaid with extended runway centerline' logic and the 'penalise transmitters at the opposite runway end' logic.

In general things are more readable because I've replaced the Navaid type enum, and the use of Robin's integer type codes, with   switches on the FGPositioned::Type code - no more trying to recall that '6' is an outer marker in Robin's data. The creation code path is also pushed down from navdb into navrecord itself.
2008-09-12 08:46:15 +00:00
ehofman
aa78341698 James Turner:
Convert FGRunway to be heap-based, and inherit FGPositioned. This is a large, ugly change, since FGRunway was essentially a plain struct, with no accessors or abstraction. This change adds various helpers and accessors to FGRunway, but doesn't change many places to use them - that will be a follow up series of patches. It's still a large patch, but outside of FGAirport and FGRunway, mostly mechanical search-and-replace.

An interesting part of this change is that reciprocal runways now exist as independent objects, rather than being created on the fly by the search methods. This simplifies some pieces of code that search for and iterate runways. For users who only want one 'end' of a runway, the new 'isReciprocal' predicate allows them to ignore the 'other' end. Current the only user of this is the 'ground-radar' ATC feature. If we had data on which runways are truly 'single-ended', it would now be trivial to use this in the airport loader to *not* create the reciprocal.
2008-09-11 08:38:09 +00:00
ehofman
3b486e1aee James Turner:
Here's part 2 - converting FGFix (the simplest one) to be both heap-based and inherit FGPositioned. One minor benefit from this is replacing some dangerous code in FGFixList which used to return the address of an iterator member ('&it->second'). To keep the diff a sensible size, I'm not updating the callers to use the richer FGPositioned types - i.e replacing separate lat/lon handling with SGGeod. I will make those cleanups, but in future patches.
2008-09-10 08:54:49 +00:00
fredb
9751b25216 Add required include for lower_bound 2008-09-08 19:25:45 +00:00
ehofman
a727e69585 James Turner:
Here's the very first FGPositioned patch - adding the files, and building them, but nothing else.
2008-09-08 17:50:06 +00:00
fredb
b53badf201 Stefan C. Mller :
Small patch fixing bugs I've encountered while getting the current CVS to build in MSVC.
* std::lower_bound was used with the key-type of a map, but lower_bound expects the value-type of the collection it works on, with is std::pair. MSVC seems to be more strict about this.
* Added an missing include statement.
* Replaced an rint() call with floor() (MSVC does not offer rint).
2008-08-31 18:32:43 +00:00
ehofman
d8f5529d21 remove redundant semi-colon 2008-08-23 13:09:24 +00:00
ehofman
341216e56a Fix a compile problem for lower_bound() 2008-08-22 19:49:03 +00:00
ehofman
289f2f5f0d James Turner:
This is a little intrusive on the KLN89 code, but avoids the wasteful cloning of the airports, runways and navaids which current happens, and also combines the ugly string ordering code.
2008-08-22 11:22:22 +00:00
durk
301054204e James Turner: Improved runway management code:
- Runways are now part of an airport, instead of a separate list
 - Runways are no longer represented as a boring struct, but as a class
   of their own.
 -Improved runway access to unify various runway access methods.
2008-08-14 18:13:39 +00:00
ehofman
c4a38e10ec James Turner:
Attached patch + new file make FGNavRecord have a .cxx file, and a constructor w
hich allows all the parameters to be supplied. Along the way I also cleaned up t
he navrecord.hxx header, lots more header pollution has been killed.

Some long methods are no longer inline, but were all suspiciously long to meet c
ompiler inlining criteria (I'm not clear if the 'inline' keyword is advisory or
mandatory in this situation) - I don't expect this to affect performance in any
way whatsoever.

The constructor addition is to support some hacking I'm doing improving the star
tup performance of the navDB by lazily loading the data, and caching it in a mor
e efficient format than text. I'm submitting this change (and probably some othe
r small tweaks in the future) since they are worthwhile as cleanups regardless o
f how my current experiments work out.
2008-08-03 14:34:42 +00:00
ehofman
429f2530de James Turner:
* experimental clean-up / reduction on two of the FG headers:
   (I'm going to await feedback on the developers list before doing more of
    these, to avoiding going over files multiple times, but in principle it
    seems pretty straightforward.)

 * final fixes for SG_USING_STD removal
2008-07-29 08:27:48 +00:00
ehofman
667e64e1eb - remove the SG_GLxxxx_H #defines, since OSG provides its own versions
- this exposed a bizarre issue on Mac where dragging in <AGL/agl.h> in
   extensions.hxx was pulling in all of Carbon to the global namespace
   - very scary. As a result, I now need to explicitly include CoreFoundation
   in fg_init.cxx.
 - change SG_USING_STD(x) to using std::x
2008-07-27 16:25:13 +00:00
ehofman
d9bfd5a425 This should apply, and everything should build cleanly, in isolation from the
SimGear change. It changes all the SG_xxxx to be the 'real' includes, and gets
rid of many #ifdef SG_HAVE_STD_INCLUDES. As an added bonus, rather than
replacing 'SG_USING_NAMESPACE(std)' with 'using namespace std', I just fixed
the small number of places to use std:: explicitly. So we're no longer polluting
the global namespace with the entire contents of std, in many cases.

There is one more 'mechanical' change to come - getting rid of SG_USING_STD(X),
but I want to keep that separate from everything else. (There's another
mechnical change, replacing <math.h> with <cmath> and so on *everywhere*, but
one step at a time)
2008-07-25 18:38:29 +00:00
ehofman
eccddb3dfd Attached patches remove BORLANDC, and hence SG_MATH_EXCEPTION_CLASH and SG_INCOM
PLETE_FUNCTIONAL from SimGear and FlightGear.

As a result, SG_HAVE_STD_INCLUDES is now *always* set, so I will get the boring
fixes for that done, but separately. I'm still auditing the other things in comp
ilers.h - there's a lot that can die now BORLAND is gone.
2008-07-25 10:39:53 +00:00
ehofman
6c4061bdc5 Remove the remaining macintosh (not MacOS-X) and MWERKS workarounds. 2008-07-25 07:29:20 +00:00
timoore
32e9505eed Clean up header file use of iostream and "using" declarations
Replace include <iostream> with istream, ostream and/or iosfwd as
appropriate.

Remove using namespace std and using std::foo from header files.
2008-06-02 21:09:51 +00:00
timoore
a251fd35cb Include <iostream> and using declarations as needed.
SimGear no longer includes iostream and avoids using declarations in
header files, so various fixups are needed.
2008-06-02 21:07:35 +00:00
mfranz
3842fa0edc Csaba "Jester" HALASZ:
Attached patch adds support for multiple FIXes with the same name.
Applies to both branches.
New functionality is in query_and_offset, which now returns the FIX
closest to the passed in location.
Updated route manager to take advantage of this.

Otherwise, query functions return an unspecified member from the set
of identically named FIXes. (This was previously the one occurring
last in the database file, but I don't think anybody counted on that.)
2008-04-28 11:26:02 +00:00
durk
270444a675 Use SGSharedPointer instead of the ssgSharedPointer from the plib branch. 2007-10-20 18:28:22 +00:00
durk
f5e9e1898f Miscellaneous tweaks and Bugfixes. Mostly memory leaks ported from the plib
version
* Delete ai list objects in ~ATC/AIMgr.cxx:AIMgr::~AIMgr()
* Delete colors in GUI/new_gui.cxx: NewGui::~NewGui.cxx
* Delete memory allocated to the class member "route" in
  Instrumentation/gps.cxx
* Delete all globals (except a few "unsafe" ones that still cause segfaults
  and need further examination.
* Use an SGShared pointer for navaid memory allocation, so that pointers to
  individual navaid objects can be included safely in multiple navaid lists
2007-10-20 08:36:21 +00:00
mfranz
5f9d70fce6 cleaner & faster (don't use STL functions ::size() and ::end() in loop
condition statements, don't use multiple vector array access via index)
2007-10-11 15:33:24 +00:00
mfranz
97d3b07a1f prevent endless loop. The new awy.dat.gz has entries like line 2632 ...
AMIBO  34.973889  021.658056 ARLOS  34.625278  023.000000 1 095 195 M871-MT E-MT W-N4
... where unexpected ids follow (here E-MT W-N4). The loader didn't skipeol.
The additional values are for a first quick&dirty fix just dropped.
2007-10-11 13:51:11 +00:00
mfranz
4022edc5ba make that __MWERKS__ :-} 2007-10-11 09:28:05 +00:00
mfranz
b66ea980ad Make sure the __MWERKS__ test can't go unnoticed. It's really time to
remove all those 41 hacks if possible. Metrowerks is under category
"Defunct software companies" in Wikipedia, its compiler was known to
work on PowerPC (which we don't support, anway, right?) and on some
Unices. The hacks are in CVS since the first commit 2002/9/10 (old
repository!) and probably were in the code long before that. Any
platform where such a broken compiler is still used, will hardly
be suitable to run fgfs at all.
2007-10-11 09:19:49 +00:00
mfranz
6e72aa6a57 checking the brutal way whether the 41 ugly __MWERKS__ hacks are really
still needed. At some point they must have fixed their broken compiler.
2007-10-10 18:34:28 +00:00
frohlich
96872a73cb Modified Files:
src/Navaids/awynet.cxx src/Navaids/awynet.hxx: Olaf Flebbe:
	Implement ~FGAirwayNetwork, though it is not called now
	Guard snprint properly.
2007-02-14 17:51:23 +00:00
frohlich
4101e6791b Modified Files:
Navaids/navdb.cxx: Olaf Flebbe: plug memory leak.
2007-02-09 05:35:10 +00:00
frohlich
b0f9d24f9d Modified Files:
configure.ac src/AIModel/AIAircraft.cxx src/AIModel/AIBase.cxx
 	src/AIModel/AIBase.hxx src/AIModel/AICarrier.cxx
 	src/AIModel/AICarrier.hxx src/AIModel/AIManager.cxx
 	src/AIModel/AIManager.hxx src/ATC/AIEntity.cxx
 	src/ATC/AIEntity.hxx src/ATC/AIMgr.cxx src/ATC/AIMgr.hxx
 	src/ATC/ATCdisplay.cxx src/ATC/ATCdisplay.hxx
 	src/Cockpit/cockpit.cxx src/Cockpit/cockpit.hxx
 	src/Cockpit/hud.cxx src/Cockpit/hud.hxx
 	src/Cockpit/hud_rwy.cxx src/Cockpit/panel.cxx
 	src/Cockpit/panel.hxx src/Cockpit/built_in/FGMagRibbon.cxx
 	src/Cockpit/built_in/FGMagRibbon.hxx src/FDM/flight.cxx
 	src/FDM/groundcache.cxx src/FDM/groundcache.hxx
 	src/GUI/gui_funcs.cxx src/Input/input.cxx
 	src/Instrumentation/od_gauge.cxx
 	src/Instrumentation/od_gauge.hxx
 	src/Instrumentation/render_area_2d.cxx
 	src/Instrumentation/render_area_2d.hxx
 	src/Instrumentation/wxradar.cxx
 	src/Instrumentation/wxradar.hxx
 	src/Instrumentation/HUD/HUD.cxx
 	src/Instrumentation/HUD/HUD.hxx
 	src/Instrumentation/HUD/HUD_runway.cxx src/Main/Makefile.am
 	src/Main/main.cxx src/Main/renderer.cxx src/Main/renderer.hxx
 	src/Main/viewmgr.cxx src/Model/acmodel.cxx
 	src/Model/acmodel.hxx src/Model/model_panel.cxx
 	src/Model/model_panel.hxx src/Model/modelmgr.cxx
 	src/Model/modelmgr.hxx src/Model/panelnode.cxx
 	src/Model/panelnode.hxx src/Navaids/awynet.cxx
 	src/Scenery/Makefile.am src/Scenery/hitlist.cxx
 	src/Scenery/hitlist.hxx src/Scenery/newcache.cxx
 	src/Scenery/scenery.cxx src/Scenery/scenery.hxx
 	src/Scenery/tileentry.cxx src/Scenery/tileentry.hxx
 	src/Scenery/tilemgr.cxx src/Scripting/NasalSys.cxx
 	src/Scripting/NasalSys.hxx src/Time/light.cxx
	Big BLOB on the way to OSG.
2006-10-29 19:30:21 +00:00
mfranz
bdf16b7b7e use correct data type for string::find() 2006-10-17 21:21:26 +00:00
durk
10ebe06285 Initial commit of code that reads and parses Robin Peel's awy.dat airway
files.
2006-07-27 14:44:09 +00:00
mfranz
2c20ef1c7f - untangle classes (methods of two classes were interwoven)
- fix mixed indentation (tabs converted to 8 spaces)
- remove trailing spaces
2006-07-10 07:59:20 +00:00
frohlich
ef52b23e3a Make more use of SGGeod 2006-06-15 19:16:21 +00:00
curt
0c85cdbd7e Additional fixes for new DME type codes. 2006-03-23 21:42:25 +00:00
david
c486dc0589 Recognize standalone DMEs (type 13 in Robin's list). 2006-03-10 03:46:50 +00:00
mfranz
c9813d1b5d new FSF address 2006-02-21 01:16:04 +00:00
daveluff
8765d770f8 The current_fixlist pointer is depreciated now that it is set in globals 2006-02-20 22:34:15 +00:00
fredb
36e4045810 Add missing include files needed by the new math code under windows 2006-02-18 13:58:09 +00:00
curt
1729d15cdd White space updates. 2006-01-24 17:13:48 +00:00
curt
fdd47f4b56 Newest data file format includes range for each transmitter. Load that data
and use it instead of our own hard coded defaults.
2006-01-24 17:13:28 +00:00
ehofman
e35911e45a Vivian: downgrade log levels from ALERT to INFO, tidy up the code. 2005-12-06 18:48:56 +00:00
daveluff
81797885ce Add a lower-bound type navaid lookup, and the ability to specify navaid type in the find nearest lookup, for the GPS code 2005-11-28 22:42:23 +00:00
daveluff
21c48ba67c Remove nav.hxx, which has been superceded by navrecord.hxx and is no longer used except by some old non-working test code 2005-11-27 23:48:04 +00:00
daveluff
808ac4784e Add a lower-bound search function for fixes for GPS units with next-match database search capabilities 2005-11-27 20:19:00 +00:00
ehofman
b24dbb3f8b Alex Romosan:
I tried to make sure accessor functions which return by reference act
on const objects. also replaced some iterators with const_iterator
and a few return/pass by reference that were missed the first time
around.
2005-10-26 09:03:49 +00:00
ehofman
62a359cc4a Alex Romosan:
* Use "const string&" rather than "string" in function calls when appropriate.
* Use "const Point3D&" instead of "Pint3D" in function calls when appropriate.
* Improved course calculation in calc_gc_course_dist()
* Safer thread handling code.

Vassilii Khachaturov:

Dont use "const Point3D&" for return types unless you're absolutely sure.

Erik Hofman:

* Use SGD_(2)PI(_[24]) as defined in simgear/constants.h rather than
  calculating it by hand every time.
2005-10-25 13:49:55 +00:00
ehofman
3188b395c8 Vassilii Khachaturov:
I found that all the current users of the companion
function, findByFreq() actually did assume radians despite the misleading
comment in the .hxx and .cxx saying it's degrees. I've fixed the
comment now, and no longer change the Navaids code. The new Navaids user
in NewWaypoint() is now passing radians to the findByIdent().

Note that along with fixing the comments in the navlist.hxx, I removed
an obsolete method findByLoc() declaration (there is no definition
anywhere).
2005-10-22 13:37:13 +00:00
mfranz
af653250b5 only skip one comment line at the top of TACAN_freq.dat.gz 2005-10-02 17:57:16 +00:00
ehofman
1c3e2d4942 Vivian Meazza:
This adds a TACAN instrument to the inventory. Range and bearing are calculated
to the TACAN or VORTAC beacon selected by means of the Channel Selector in the E
quipment/Radio pull-down menu.

A TACAN beacon has also been added to the aircraft carrier Nimitz (channel #029Y
).
2005-10-01 09:56:53 +00:00
curt
0bb1494452 David Luff:
Attached is a patch to the airport data storage that I would like committed
after review if acceptable.  Currently the storage of airports mapped by ID
is by locally created objects - about 12 Meg or so created on the stack if
I am not mistaken.  I've changed this to creating the airports on the heap,
and storing pointers to them - see FGAirportList.add(...) in
src/Airports/simple.cxx.  I believe that this is probably better practice,
and it's certainly cured some strange problems I was seeing when accessing
the airport data with some gps unit code.  Changes resulting from this have
cascaded through a few files which access the data - 11 files are modified
in all.  Melchior and Durk - you might want to test this and shout if there
are problems since the metar and traffic code are probably the biggest
users of the airport data.  I've also added a fuzzy search function that
returns the next matching airport code in ASCII sequence in order to
support gps units that have autocompletion of partially entered codes.

More generally, the simple airport class seems to have grown a lot with the
fairly recent addition of the parking, runway preference and schedule time
code.  It is no longer just an encapsulation of the global airport data
file, and has grown to 552 bytes in size when unpopulated (about 1/2 a K!).
 My personal opinion is that we should look to just store the basic data in
apt.dat for all global airports in a simple airport class, plus globally
needed data (metar available?), and then have the traffic, AI and ATC
subsystems create more advanced airports for themselves as needed in the
area of interest.  Once a significant number of airports worldwide have
ground networks and parking defined, it will be impractical and unnecessary
to store them all in memory.  That's just a thought for the future though.
2005-09-20 20:26:57 +00:00
mfranz
b68429c862 don't crash if fgfs is called with an invalid argument to the --vor option 2005-05-01 14:27:06 +00:00
ehofman
5bc15d7a69 Durk Talsma:
I just heard from John Wojnaroski that you and he are going to work on getting
a flightgear demo machine up for the linux expo thursday and Friday. John
indicated that he would very much like to get a CVS version with the new
traffic code up and running before the expo.
2005-02-10 09:01:51 +00:00
curt
222446df29 Replace the data/Airports/basic.dat.gz and data/Airports/runways.dat.gz with
a single apt.dat.gz file which is in the native X-Plane format.

To do this I wrote a front end loader than builds the airport and runway
list.  Some of the changes I needed to make had a cascading effect, so there
are minor naming changes scattered throughout the code.
2004-12-22 23:57:07 +00:00
curt
d05121ef46 Fix my mailing address by replacing it with my web page. 2004-11-19 22:10:41 +00:00
curt
abb0221c74 Make distance penalty math for opposite oriented navaids more correct. 2004-07-20 00:59:17 +00:00
curt
d5a5c9bb0e Ed Sirett submitted a patch to consider antenna orientation when searching
for localizers.  I further hacked this to support GS and DME transmitters
(although Robin's DME transmitter data doesn't convey orientation
unfortunately.)
2004-07-19 18:02:00 +00:00
curt
258cd292c6 When searching for nav records ignore stations > 300nm away. 2004-06-20 18:58:44 +00:00
curt
225298a09e Often, the elevation of an ILS component is not listed in our nav database.
A good elevation is critical for proper glide slope modeling.  This patch
assigns the average field elevation to any ILS component that doesn't have
a valid elevation.

Also, for an ILS approach, use the GS transmitter elevation for glide slope
calculations rather than the localizer elevation, in some cases this can
make a big difference.
2004-06-09 03:13:13 +00:00
ehofman
a3c8bc99a2 Incorporate some of the changes from the Linspire diff. 2004-06-06 14:28:45 +00:00
curt
a08f4c084b Allow a "threshold" value to determine which localizers to snap to the
runway heading or not.
2004-05-28 20:57:05 +00:00
curt
a3cde21637 Curt Olson:
These change add some code that at initialization time will snap all
localizers into perfect alignment with their runways.  It's my experience
that the DAFIF/FAA data reports runway and localizer headings to a level
of precision that is great for making charts, or adjusting your OBS, etc.
But the level of precision of this data can be far enough off to make you
visibly *un*aligned with the runway when the CDI needle is centered.

There are probably cases where the localizer isn't really perfectly
aligned with the runway, or intentionally misaligned to avoid obstacles
or terrain.  So I have made this configurable for those that trust the
data more than I do.  Just set "/sim/navdb/auto-align-localizers" to
true/false in the preferences file to turn this feature on or off in the
code.
2004-05-28 16:24:43 +00:00
curt
1b5483bc63 And again ... 2004-05-28 05:33:10 +00:00
curt
b2b33f7582 This set of changes impliments the following:
- FG now directly supports Robin's native nav database file format.
- His latest data now separates out dme, gs, loc, and marker beacon
  transmitters rather than lumping them all into a single "ILS" record.
- These new data structure changes prompted me to do some code restructuring
  so that internally these different types of navaids are all kept as
  separate lists and searched and handled separately.
- This structural change had a cascading affect on any code that
  references or uses the nav databases.  I've gone and "touched" a lot of
  nav related code in a lot of places.
- As an added bonus, the new data (and code) adds DME bias so these will
  all now read as they do in real life.

- Added Navaids/navdb.cxx and Navaids/navdb.hxx which provide a front
  end loaders for the nav data.
- Added Navaids/navrecord.hxx which is a new "generic" nav data record.
- Removed Navaids/ils.hxx, Navaids/ilslist.cxx, Navaids/ilslist.hxx,
  Navaids/mkrbeacons.cxx, and Navaids/mkrbeacons.hxx which are all now
  depricated.
2004-05-28 05:24:54 +00:00
curt
78e6d35998 Move navaids and fixes out of "global" name space into the FGGlobals
structure.
2004-05-26 18:15:19 +00:00
curt
d777d035a9 Update fix management code to read Robin's native fix.dat format. 2004-05-26 16:40:27 +00:00
curt
00002357b3 Roy Vegard Ovesen:
I've done som more work on the gps instrument.

- You can now input airport-, nav- or fix-ID to select a waypoint.
- You have to specify either "airport", "nav" or "fix" in the waypoint-type
  property (some fixes and navs have identical IDs).
- Formatted the time to waypoint output.
- Cleaned up and changed some propery names (wp-heading -> wp-bearing).

- I've also added a name member to the FGNav class so that the gps instrument
  can get the name of the nav.
- Changed the airport name parsing in simple.cxx.
2004-03-15 19:23:39 +00:00
curt
5c0ae1c6f6 Resolve a meters vs. feet interpretation problem with nav station elevations. 2004-03-14 23:01:44 +00:00
andy
439a9fa1e4 Minor API changes to support the new sg_geodesy implementation. A few
places now use sgCartToGeod() instead of rolling their own
approximation.  And YASim is now using exactly the same 3D coordinate
system as the rest of FlightGear is.
2003-12-19 02:42:32 +00:00
ehofman
3ba01fa762 New automake, new problems. Add $base_LIBS for programs since $LIBS isn't substituted automatically anymore 2003-08-29 09:03:49 +00:00
david
d403c2e568 The lookup method was always skipping the first ILS for any frequency
-- I discovered the problem while puzzling over an LOC that wouldn't
come in.
2003-05-13 14:15:30 +00:00
curt
5df9811576 I found 3 problems with the GS modeling in flightgear (all my fault originally
I believe.) :-)

- The height of the navaid was not being properly converted to meters
  before being used in our internal calculations.  This caused the GS
  to be placed too high.

- I was using the wrong trig function to calculate the current approach
  angle of the aircraft.  The distance to the GS source is the euclidean
  point to point distance and represents the hypotenuse (not the ground
  distance) so I need to use asin() rather than atan() to calculate the
  angle.

- I was calculating distance directly to the GS source, rather than
  taking into consideration that the GS transmitter projects a plane,
  so I need to take the distance to the line where that plane intersectso
  the ground.  Previously, the way I modeled my distance calculation, the
  GS transmitter effectively formed a 3 degree cone from the source.  The GS
  transmitter is usually placed a 100 meters or so off the runway edge so
  the cone model could never bring you in to the touch down point precisely.

With these changes, the GS will bring you in precisely to the touchdown
point as defined in the default.ils.gz file (it wouldn't before.)  The only
issue that remains is that it will bring you in to the elevation defined
in the ILS database, which doesn't necessarily match the DEM/SRTM terrain
at that point.  Still on average, this will be a big improvement until we
can do a better job of getting the runway end elevations nailed correctly.
2003-03-31 01:29:23 +00:00
curt
fed01db83a Oops, sorry, nothing more to see here, move right along ... 2003-02-04 17:22:00 +00:00
curt
88b98d9d79 Updated FGILSList api to better match the FGNavList api. 2003-02-03 20:05:27 +00:00
curt
8cc7b283d5 Refactored some of the navlist code and removed the built in "fail to find"
if the station is too far away.  Instead, simply return the closest station.
All the code that searches navaids does it's own range checking anyway.
This will make the navlist query functions a bit more useful for other
types of functionality where you may need to lookup a station without
consideration of range (i.e. presetting your position relative to a navaid.)
2003-01-25 20:45:39 +00:00
curt
be703a92b4 Add support for in-air preset starts relative to a VOR, NDB, or Fix. 2003-01-05 00:10:36 +00:00
david
71f08e795d Patches from Erik Hofman for SGI compatibility:
Some more cmall changes to the SimGear header files and removed the
SG_HAVE_NATIVE_SGI_COMPILERS dependancies from FlightGear.

I've added a seperate JSBSim patch for the JSBSim source tree.
2002-12-31 18:26:02 +00:00
curt
401c0afcd9 Return the closest match, not just the first match. Sometimes there
are stations with the same frequency close enough together to cause problems
for our code.
2002-09-02 05:31:46 +00:00
curt
4f00d9a959 Tidy up the autoconf/automake configuration a bit.
- Removed some old cruft.

- Removed some support for older versions of automake which technically was
  correct, but caused the newer automakes to squawk warnings during an
  initial sanity check (which isn't done very intelligently.)

  NOTE: this fix is technically not correct for older version of automake.
  These older version use the variable "INCLUDES" internally and could have
  them already set to an important value.  That is why we were appending
  our values to them.  However, newer versions of automake don't set this
  value themselves so it is an error to append to a non-existant variable.
  We seem to "get away" with overwriting the value on older versions of
  automake, but if you have problems, consider upgrading to at least
  automake-1.5.
2002-08-25 19:40:04 +00:00
curt
8b711a5782 James Turner:
Modifications to support querying navaid database by station ID (not just
frequency.)  Some corresponding changes to testnavs.cxx to test new
functionality.
2002-06-07 21:03:27 +00:00
david
1ce573908c Mac OS X patches from Jonathan Polley. 2002-05-11 12:30:22 +00:00
curt
39cba9139c Of all the ILS stations that match the specified frequency and are in range,
return the one that is pointed most directly at us.
2002-04-15 17:53:05 +00:00
david
6c2039c5aa This module was filtering out all stations with localizer offset
>90deg, even though src/Cockpit/radiostack.cxx has code to deal with
those; as a result, no backcourses were getting through.

This fix allows the common case of backcourses to work again, but
breaks the uncommon case of a runway using the same frequency for two
separate localizers.  That special case will have to be detected
somehow.  Still, this fixes more approaches than it breaks.
2002-04-15 15:28:11 +00:00
david
50e25151e1 Patch from Melchior Franz:
My last patch fixed the initialization problem only for the main branch, but
ignored the _MWERKS_ branch.
- merged the branches, only the loop head needs different treatment;
- don't access n.type before it is initialized (valgrind complaint)
- created a constructor; the operator>> wouldn't have initialized all
  variables in case of a broken default.nav.gz entry, so we would have
  got a mixture of the broken one and the previous one; in case of
  the first entry, that would have made nice random values ... ;-)
- move the automatic FGNav variable into the loop, so that the gets
  cleanly constructed for every database entry.
- commented out the frequency min/max exploration, which isn't used at all
- updated the commented out debug output statements, which were simply
  copied over from the nav* files, but never adapted (I needed them :-)
2002-03-30 12:51:42 +00:00
david
ce4ea1d432 Patch from Melchior Franz:
- merged the _MWERKS_ and the generic branch, only the loop head needs
  different treatment
- created a constructor; the operator>> wouldn't have initialized all
  variables in case of a broken default.fix.gz entry, so we would have
  got a mixture of the broken one and the previous one; (valgrind
  complained ...)
- move the automatic FGFix variable into the loop, so that the gets
  cleanly constructed for every database entry.
- don't access fix.type before it is initialized
- updated the commented out debug output statements (they were copied
  over from navlist.cxx but never adapted)
2002-03-30 12:50:01 +00:00
david
7e1b599368 Patch from Melchior Franz:
When the loop starts, n.type is still undefined, so the while statement
depends on unitialized garbage. The input operator cares for the [End]
bracket anyway (returns if the first character is a '['). So it is safe
to check for it after reading the line and break if necessary.
2002-03-27 12:49:29 +00:00
curt
e95429572c Converted if ( string == "" ) constructs to if ( string.empty() )
Fixed a warning in soundmgr.cxx.
2002-03-20 19:16:13 +00:00
curt
4f67824f09 - Removed redundant FG*:: qualifications from class members
- Fixed comparisons between signed and unsigned ints
2002-02-15 22:00:49 +00:00
curt
dd8852dabe Better support for an alternate calendar time (i.e. if time/position/etc.
are being driven from an external data source.)

Akso found and fixed a bug in the simgear that caused the time to go goofy
temporarily while scenery was being loaded.
2002-02-11 23:33:20 +00:00
curt
aad1de2ee5 Changes to match simgear changes which allow overriding the current
clock time.
2002-02-10 04:18:10 +00:00
curt
1fa4c88d0e Updates to build system to better support automake-1.5
- automake-1.4 sets default values for INCLUDES which we can't
  overwrite.
- automake-1.5 renames this to DEFAULT_INCLUDES and leaves INCLUDES
  open for the developer to use.

Thus for automake-1.4 we are forced to 'append' to INCLUDES and in
automake-1.5 we can just set the value to whatever we like.
Unfortunately, the behaviors of the two versions are mutually
incompatible.

The solution I am committing now works for both versions but
automake-1.5 generates a lot of spurious warning messages that are
annoying, but not fatal.
2001-12-28 22:29:59 +00:00