pub struct Datum { /* private fields */ }Expand description
Horizontal geodetic datum: ellipsoid and its transformation to WGS 84.
Each provided datum uses the EPSG transformation for its home area, with the accuracy EPSG states: a few metres for a modern seven-parameter fit, tens of metres for a continental mean translation. This is the accuracy of the shift, not of the chart; a chart’s own datum note, when present, takes precedence over this table.
Implementations§
Source§impl Datum
impl Datum
Sourcepub const NAD83: Self
pub const NAD83: Self
NAD83, on GRS 80. Equivalent to WGS 84 at chart accuracy: EPSG 1188 (identity), 4 m.
Sourcepub const ED50: Self
pub const ED50: Self
ED50, on International 1924: western European charts before ETRS 89. EPSG 1133 (Europe mean), 10 m.
Sourcepub const PULKOVO_1942: Self
pub const PULKOVO_1942: Self
Pulkovo 1942, on Krassowsky 1940: Russian and former-USSR charts. EPSG 5044 (GOST R 51794-2001, Russia), 3 m. Published in the coordinate frame convention; stored here in the position vector convention.
Sourcepub const TOKYO: Self
pub const TOKYO: Self
Tokyo, on Bessel 1841: Japanese and Korean charts before JGD 2000. EPSG 1230 (Japan and South Korea mean), 29 m; the shift itself exceeds 400 m.
Sourcepub const DHDN: Self
pub const DHDN: Self
DHDN (Potsdam), on Bessel 1841: German charts before ETRS 89. EPSG 1777 (Germany), 3 m.
Sourcepub const AGD66: Self
pub const AGD66: Self
AGD66, on the Australian National Spheroid. EPSG 15788 (Australia mean), 5 m.
Sourcepub fn new(
name: &'static str,
ellipsoid: Ellipsoid,
to_wgs84: Helmert,
accuracy: Distance,
) -> Self
pub fn new( name: &'static str, ellipsoid: Ellipsoid, to_wgs84: Helmert, accuracy: Distance, ) -> Self
Datum from its ellipsoid, transformation to WGS 84 and stated accuracy: for datums not in the table, or with parameters from a chart note.
Sourcepub const fn to_wgs84_helmert(&self) -> &Helmert
pub const fn to_wgs84_helmert(&self) -> &Helmert
Transformation from this datum’s geocentric frame to WGS 84.
Sourcepub fn to_wgs84(&self, position: Position) -> Result<Position>
pub fn to_wgs84(&self, position: Position) -> Result<Position>
Chart position on this datum → WGS 84.
Placed on the datum ellipsoid at zero height, transformed via ECEF, read back on WGS 84. A ship is within ~100 m of the ellipsoid and the shift tilts the normal by ≤ 0.1 mrad, so dropping height costs about 1 cm.
§Errors
KernelError::Indeterminate if the transformed point has no geodetic
position; impossible with published parameters, possible with arbitrary
Helmert values.
Sourcepub fn from_wgs84(&self, position: Position) -> Result<Position>
pub fn from_wgs84(&self, position: Position) -> Result<Position>
WGS 84 position (GNSS fix) → position on this datum, for plotting on its chart.
Exact inverse of Datum::to_wgs84 apart from the height dropped at
each end: round trip closes to ~1 cm in the datum’s home area, a
decimetre or two on the far side of the Earth where its ellipsoid is
kilometres from WGS 84.
§Errors
As Datum::to_wgs84.