mirror of
https://github.com/ClemensFischer/XAML-Map-Control.git
synced 2026-04-08 16:05:50 +00:00
MapProjection.Factory
This commit is contained in:
parent
c2a0fd836e
commit
616b2bf3f7
5 changed files with 36 additions and 89 deletions
|
|
@ -31,6 +31,14 @@ namespace MapControl
|
|||
public const double Wgs84Flattening = 1d / 298.257223563;
|
||||
public static readonly double Wgs84Eccentricity = Math.Sqrt((2d - Wgs84Flattening) * Wgs84Flattening);
|
||||
|
||||
private static MapProjectionFactory factory;
|
||||
|
||||
public static MapProjectionFactory Factory
|
||||
{
|
||||
get => factory ??= new MapProjectionFactory();
|
||||
set => factory = value;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Gets the type of the projection.
|
||||
/// </summary>
|
||||
|
|
@ -147,7 +155,7 @@ namespace MapControl
|
|||
/// </summary>
|
||||
public static MapProjection Parse(string crsId)
|
||||
{
|
||||
return MapProjectionFactory.Instance.GetProjection(crsId);
|
||||
return Factory.GetProjection(crsId);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue