diff options
author | Eric S. Raymond <esr@thyrsus.com> | 2005-04-30 15:08:00 +0000 |
---|---|---|
committer | Eric S. Raymond <esr@thyrsus.com> | 2005-04-30 15:08:00 +0000 |
commit | cf486a2e716a818add61382d5ffaa7f87822a3a5 (patch) | |
tree | f39409e2e9ba9b26ac0fa98ac6e3d928d0ee6bc8 /geoid.c | |
parent | 41fd328ea2efca4ed44b1928b40ac2c1938ceca8 (diff) | |
download | gpsd-cf486a2e716a818add61382d5ffaa7f87822a3a5.tar.gz |
Fixes from Rob Janssen.
Diffstat (limited to 'geoid.c')
-rw-r--r-- | geoid.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -89,7 +89,8 @@ void ecef_to_wgs84fix(struct gps_fix_t *fix, h = p / cos(phi) - n; fix->latitude = phi * RAD_2_DEG; fix->longitude = lambda * RAD_2_DEG; - fix->altitude = h - wgs84_separation(fix->latitude, fix->longitude); + fix->separation = wgs84_separation(fix->latitude, fix->longitude); + fix->altitude = h - fix->separation; /* velocity computation */ vnorth = -vx*sin(phi)*cos(lambda)-vy*sin(phi)*sin(lambda)+vz*cos(phi); veast = -vx*sin(lambda)+vy*cos(lambda); |