Web tiled layer

View inMAUIUWPWPFWinUIView on GitHub

Display a tiled web layer.

Image of web tiled layer

Use case

Tiled map services are a set of pre-generated images (e.g. "tiles") arranged in folders for each row, column, and zoom level. As you navigate the map, map tiles are requested for the current extent. ArcGISTiledLayer and WMTSLayer are types of tiled map services used for specific data types. WebTiledLayer is useful for displaying other data sources that contain tiles arranged in a row/column/level directory structure, such as OpenStreetMap.

How to use the sample

Run the sample and a map will appear. As you navigate the map, map tiles will be fetched automatically and displayed on the map.

How it works

  1. Create a WebTiledLayer from a URL and a list of subdomains.
  2. Create a new Basemap from the layer.
  3. Update the attribution on the layer. Note: this is a necessary step because web tiled services don't have associated service metadata.
  4. Display the basemap.

Relevant API

  • Basemap
  • WebTiledLayer

About the data

The basemap in this sample is provided by Stamen Design. Stamen publishes tiled services based on OpenStreetMap data with several unique styles applied.

Additional information

Web tiled services use a uniform addressing scheme with pre-rendered tiles. Image tiles are accessed via a URL template string, with parameters for subdomain, level, column, and row.

  • Subdomain is optional and allows Runtime to balance requests among multiple servers for enhanced performance.
  • Level, row, and column select the tiles to load based on the visible extent of the map.

For more information about web tiled layers, see the following resources:

Tags

layer, OGC, Open Street Map, OpenStreetMap, stamen.com, tiled, tiles

Sample Code

LoadWebTiledLayer.xamlLoadWebTiledLayer.xamlLoadWebTiledLayer.xaml.cs
Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
9
<UserControl
    x:Class="ArcGIS.UWP.Samples.LoadWebTiledLayer.LoadWebTiledLayer"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:esriUI="using:Esri.ArcGISRuntime.UI.Controls">
    <Grid>
        <esriUI:MapView x:Name="MyMapView" />
    </Grid>
</UserControl>

Your browser is no longer supported. Please upgrade your browser for the best experience. See our browser deprecation post for more details.