Function LambertAzimuthalEqualArea.tryForward
Project a geographic coordinate without throwing.
bool tryForward(
const GeographicCoordinate!T source,
out ProjectedCoordinate!T result
) const pure nothrow @nogc @safe;
Example
Example projecting a geographic coordinate without throwing.
import geodesy;
const projection =
LambertAzimuthalEqualArea!double .fromParameters(
wgs84!double(),
Latitude!double .fromDegrees(52.0),
Longitude!double .fromDegrees(10.0),
4_321_000.0,
3_210_000.0);
ProjectedCoordinate!double projected;
assert(projection .tryForward(
GeographicCoordinate!double .fromComponents(
Latitude!double .fromDegrees(48.20849),
Longitude!double .fromDegrees(16.37208)),
projected));