geocentric property
A projection adapter between WGS84 geographic and geocentric cartesian positions (using the WGS84 ellipsoidal datum).
Use forward
of the adapter to return a projection for:
- source:
lon
,lat
andelev
(h) geographic coordinates (WGS 84) - target:
x
,y
andz
coordinates ("EPSG:4978", WGS 84 / geocentric)
Use inverse
of the adapter to return a projection for:
- source:
x
,y
andz
coordinates ("EPSG:4978", WGS 84 / geocentric) - target:
lon
,lat
andelev
(h) geographic coordinates (WGS 84)
Other coordinates, if available in the source and if expected for target
coordinates, are just copied (m
<=> m
) without any changes.
The accuracy on conversions using other than the Datum.WGS84 datum is not guaranteed. The accuracy depends on the transformation parameter of the Helmert 7-parameter transformation used in the conversion.
Implementation
static final ProjectionAdapter geocentric =
EllipsoidalProjectionAdapter.geographicToGeocentric(
// source is geographic coordinates in WGS 84
sourceCrs: CoordRefSys.CRS84,
sourceDatum: Datum.WGS84,
// target is geocentric coordinates in WGS 84
targetCrs: CoordRefSys.EPSG_4978,
targetDatum: Datum.WGS84,
);