mirror of
https://github.com/ClemensFischer/XAML-Map-Control.git
synced 2026-04-08 16:05:50 +00:00
Fixed TileSource (14.2.0)
This commit is contained in:
parent
ef7849948e
commit
36883a8d9d
6 changed files with 49 additions and 20 deletions
|
|
@ -24,6 +24,11 @@ namespace MapControl
|
|||
/// </summary>
|
||||
public partial class MapTileLayer : TilePyramidLayer
|
||||
{
|
||||
private const int TileSize = 256;
|
||||
|
||||
private static readonly Point MapTopLeft = new(-180d * MapProjection.Wgs84MeterPerDegree,
|
||||
180d * MapProjection.Wgs84MeterPerDegree);
|
||||
|
||||
public static readonly DependencyProperty MinZoomLevelProperty =
|
||||
DependencyPropertyHelper.Register<MapTileLayer, int>(nameof(MinZoomLevel), 0);
|
||||
|
||||
|
|
@ -33,11 +38,6 @@ namespace MapControl
|
|||
public static readonly DependencyProperty ZoomLevelOffsetProperty =
|
||||
DependencyPropertyHelper.Register<MapTileLayer, double>(nameof(ZoomLevelOffset), 0d);
|
||||
|
||||
private const int TileSize = 256;
|
||||
|
||||
private static readonly Point MapTopLeft = new(-180d * MapProjection.Wgs84MeterPerDegree,
|
||||
180d * MapProjection.Wgs84MeterPerDegree);
|
||||
|
||||
/// <summary>
|
||||
/// A default MapTileLayer using OpenStreetMap data.
|
||||
/// </summary>
|
||||
|
|
@ -48,6 +48,11 @@ namespace MapControl
|
|||
Description = "© [OpenStreetMap Contributors](http://www.openstreetmap.org/copyright)"
|
||||
};
|
||||
|
||||
public MapTileLayer()
|
||||
{
|
||||
MapPanel.SetRenderTransform(this, new MatrixTransform());
|
||||
}
|
||||
|
||||
public override IReadOnlyCollection<string> SupportedCrsIds { get; } = [WebMercatorProjection.DefaultCrsId];
|
||||
|
||||
public TileMatrix TileMatrix { get; private set; }
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue