Function tryReverseUtm
Reverse a tagged UTM coordinate using its explicit zone and hemisphere.
bool tryReverseUtm(T)(
const UtmCoordinate!T source,
const Ellipsoid!T ellipsoid,
out GeographicCoordinate!T result
) pure nothrow @nogc @safe
if (isGeodesyScalar!T);
The result is not automatically reassigned to another zone or hemisphere.
Parameters
| Name | Description |
|---|---|
| source | Structurally valid tagged UTM coordinate in metres. |
| ellipsoid | Supported terrestrial oblate ellipsoid in metres. |
| result | Receives the geographic coordinate on success. |
Returns
true when explicit-zone preparation and delegated reverse TM
projection succeed; otherwise false. On failure result remains
unchanged.
Example
Example reversing a tagged UTM coordinate without throwing.
import geodesy;
const vienna = GeographicCoordinate!double .fromComponents(
Latitude!double .fromDegrees(48.20849),
Longitude!double .fromDegrees(16.37208));
const utm = forwardUtm(vienna, wgs84!double());
GeographicCoordinate!double result;
assert(tryReverseUtm(utm, wgs84!double(), result));
assert(result .latitude .degrees > 48.0);