Exporting Vector Tile Package

5907
14
Jump to solution
01-30-2019 05:57 AM
MichalStolba
New Contributor II

I am trying to export vector tiles (.vtpk) for offline use, preferably from https://www.arcgis.com/home/item.html?id=f42ec2699c7d4819bbbe60eca31b6b3e  or even better the vector variant of Light Gray Canvas (I would even like to do some edits to the map or add my own style).

I am trying to do it via ArcGIS Pro, but regardless of what I try, I get Error 00102 "Map does not contain a required layer type for web vector tile layer"

What am I doing wrong?

Or could you suggest some other way to do the desired task? I have also tried Tile Package Kreator but id does not seem to support vector tiles.

14 Replies
ahargreaves_FW
Occasional Contributor III

Thanks for the quick reply. 

It works with the navigation map.

Thanks

0 Kudos
davedoesgis
Occasional Contributor III

Pro 3.0.2 doesn't ask me where to store it or what to name it. It created a "VectorTileMaps" folder under my APRX's folder and put it there with a giant GUID (ID number) in the VTPK's file name.

0 Kudos
davedoesgis
Occasional Contributor III

Does anyone know how to specify an extent, rather than just using the current map extent? My map is really huge and I'm drawing it at 1:480,000. The drop-down for the scale has 1.1M as the most zoomed-in extent.

dcafdg_0-1684285648806.png

 

My guess is that my map is just so big that it doesn't want to let me download that many features/tiles. It feels like I need to export this in tiles, and using screen extent feels rather imprecise. I can't find a GeoProcessing tool to do this, but maybe I'm missing something. Any other ideas?

Or, if I download slightly overlapping areas, can I clip them to create meta-tiles (of tiled layers)?

0 Kudos
BrettLessner
Occasional Contributor

@davedoesgis,

Not that I've seen. The tool says "Pan and zoom the map to determine the area to download." In my experience, that was the only way to change extent of the export. If you play around with your current map extent you'll see that the larger scales become available in the Max scale dropdown as you zoom in.

Overall, there just isn't a place to set parameters like one can in the Export Tile Cache and Manage Tile Cache tools. 

-Brett

0 Kudos
davedoesgis
Occasional Contributor III

@BrettLessner- Agreed. If there's a GP tool or some API, I'm not aware of it, so it looks like the current map extent is the only way to set the extent.

If you have to download it in multiple extents to get the scale you want, you want tiles that are non-overlapping. Many of the polygonal features, like parks, use partial transparency to display a hillshade behind it. Any overlap will really stand out. I found some Python code to map the extent of a map and it ran, but did nothing. Not sure if I was doing it wrong, but I couldn't get it to work. Very similar code applied to a layout worked. If you activate the layout, the download map function is enabled. Here, I have downloaded the map for the current map extent and pan the map to the right/east by exactly the width of current extent to get non-overlapping extents.

# Activate the map frame in the layout you will use.
# Save vector tiles for current extent before running this. 
	
aprx=arcpy.mp.ArcGISProject("CURRENT")
lyt = aprx.listLayouts('VTPK download and clipping')[0]
mf = lyt.listElements("mapframe_element", 'VTPK download and clipping')[0]
extent = mf.camera.getExtent()
width = extent.XMax - extent.XMin
extent2 = arcpy.Extent(XMin = (extent.XMin + width), 
              YMin = extent.YMin,
              XMax = (extent.XMax + width), 
	      YMax = extent.YMax,
	      spatial_reference = extent.spatialReference)
mf.camera.setExtent(extent2) 
	
# Now save the vector tiles for the new extent

 

As far as I could zoom in on screen, everything seamed together perfectly.

 

0 Kudos