mirror of
https://github.com/ClemensFischer/XAML-Map-Control.git
synced 2026-04-08 16:05:50 +00:00
Updated StereographicProjection
This commit is contained in:
parent
a3d25b5084
commit
1d62a6e9f3
2 changed files with 27 additions and 18 deletions
|
|
@ -1,5 +1,4 @@
|
|||
using System;
|
||||
using System.Globalization;
|
||||
|
||||
namespace MapControl
|
||||
{
|
||||
|
|
@ -33,16 +32,7 @@ namespace MapControl
|
|||
|
||||
if (projection == null && crsId.StartsWith(StereographicProjection.DefaultCrsId))
|
||||
{
|
||||
var parameters = crsId.Split(',');
|
||||
|
||||
if (parameters.Length == 4 &&
|
||||
parameters[0] == StereographicProjection.DefaultCrsId &&
|
||||
parameters[1] == "1" &&
|
||||
double.TryParse(parameters[2], NumberStyles.Float, CultureInfo.InvariantCulture, out double longitude) &&
|
||||
double.TryParse(parameters[3], NumberStyles.Float, CultureInfo.InvariantCulture, out double latitude))
|
||||
{
|
||||
projection = new StereographicProjection(longitude, latitude);
|
||||
}
|
||||
projection = new StereographicProjection(crsId);
|
||||
}
|
||||
|
||||
return projection;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue