Click or drag to resize

CoordinateSet_Datum Method (Double, Double, Coordinate_Datum)

Set a custom datum for coordinate conversions and distance calculation for specified coordinate formats only. Objects must be loaded prior to setting if EagerLoading is turned off.

Namespace:  CoordinateSharp
Assembly:  CoordinateSharp (in CoordinateSharp.dll) Version: 2.12.1.1
Syntax
C#
public void Set_Datum(
	double radius,
	double flattening,
	Coordinate_Datum datum
)

Parameters

radius
Type: SystemDouble
Equatorial Radius
flattening
Type: SystemDouble
Inverse Flattening
datum
Type: CoordinateSharpCoordinate_Datum
Coordinate_Datum
Examples
The following example demonstrates how to set the earths ellipsoid values for UTM/MGRS conversions only.
//Initialize a coordinate with the default WGS84 Ellipsoid that eagerloads UTM/MGRS only.
EagerLoadType et = EagerLoadType.UTM_MGRS;
EagerLoad eagerLoad = new EagerLoad(et);
Coordinate c = new Coordinate(25, 25, et);

//Change Ellipsoid to GRS80 Datum for UTM_MGRS calculations only.
c.Set_Datum(6378160.000, 298.25, Coordinate_Datum.UTM_MGRS);
See Also