
Create Tiled Imagery Basemaps From Mosaic Datasets
Create basemaps tailored to your organisation using Cloud Imagery of Aotearoa.
Background
In September 2023, Toitū Te Whenua (LINZ) announced that 20TB of their imagery has been made available in a cloud-optimised format using Amazon Web Services (AWS). This is exciting news, as it allows users to add imagery and create mosaic datasets directly from the cloud.
The second StoryMap in this collection covered how to create Mosaic Datasets from cloud-based imagery sourced from the AWS S3 Bucket provided by Toitū Te Whenua.
This StoryMap will detail how to create tiled imagery layers from the mosaicked datasets using tile cache. Tile cache allows for fast visualisation of large datasets by using a collection of pre-drawn, static tiles at different resolutions. Tile caching is suitable for imagery basemaps as they are static and don't change regularly.
Later in 2024, elevation data will also be made available through a public S3 bucket.
Workflow
Firstly, you will need to create a tiling scheme for the imagery to define the tiling grid and image format using the ' Generate Tile Cache Tiling Scheme ' tool. This tool allows for the editing of existing tiling schemes: For this workflow, we will import the existing Eagle Basemap Tiling Scheme and make some adjustments to its properties.
Parameters for the 'Generate Tile Cache Tiling Scheme' tool
Step 1: Generating the Tiling Scheme
Input Data Source The Mosaic Dataset you will be using to create your tile cache.
Output Tiling Scheme Specify the file name and where you want to store the file.
Generation Method / Predefined Tiling Scheme Setting the method to Predefined will allow you to import an existing tiling scheme, such as Eagle's basemap tiling scheme. This will display all scales from the specified scheme.
The most important parameter to adjust in the Advanced Options section will be setting Tile Format to Mixed compression instead of JPEG. While JPEG is good for imagery in general, the edges of the imagery may not look right. PNGs are more effective on the edges as JPEGs don't support transparency. Selecting mixed compression allows for the best of both, by creating PNGs wherever transparency is detected while creating JPEGs everywhere else.
For this example, the Tile Compression Quality will be set to 80, while the default is 75.
The Storage Format should be set to Compact.
Once you have run the tool above, you will have an .XML file for the tiling scheme you just generated. The next tool to run is 'Manage Tile Cache' to generate the tile layer.
Step 2: Creating the Tile Layer
Parameters for the 'Manage Tile Cache' tool
Cache Location: Where you'd like to store the tile layer.
Manage Mode: As this tile layer is being created from scratch, either 'Recreate all tiles' or 'Recreate empty tiles' should work here.
Input Data Source: Either the mosaic dataset you are building the tile layer from or a map with the mosaic dataset in it.
Input Tiling Scheme / Import Tiling Scheme: Set this to Import Scheme in order to select the tiling scheme (.xml file) you created from the previous tool.
Once you have input the tiling scheme, it will display the scale levels from the scheme, along with the pixel size.
Set the min and max cached scale to the min and max of the tiling scheme.
Next, decide what levels you would like to cache. A good rule of thumb is cache to the level where the cache resolution matches the source resolution of the Imagery.
The area of interest defines the area that will be cached.
When caching multiple areas that aren't connected, you can create a polygon layer that combines the areas of interest. To speed up the caching process you can dissolve the different area polygons into one polygon.
The layer used for the AOI in this example is shown below.
Feature Layer for AOI of Urban Areas in Wellington
Step 3: Exporting the Tile Layer
Parameters for the 'Export Tile Cache' tool
The final tool for this workflow is ' Export Tile Cache ', which will export the tiles previously created using the 'Manage Tile Cache' tool into a Tile Package.
Input Tile Cache: This will be the tile layer you created with the 'Manage Tile Cache' tool you used in the previous step.
Output Tile Cache Location: The folder where you want the Tile Package output to be located.
Output Tile Cache Name: The name of the Tile Package output.
Export Cache as: 'Tile package (tpkx)' is the best option for this parameter, as it exports the tile cache using the Compact v2 storage format which provides better performance on cloud storage directories.
Area of Interest can be set to the same boundary that was specified in the 'Manage Tile Cache' tool, or the parameter can be left blank.
This is the last tool for data management that needs to be run before sharing the item to ArcGIS Online.
The scales that appear within the 'Export Tile Cache' tool will be the scales that were set in the 'Manage Tile Cache' Parameters.
Step 4: Sharing the Tile Layer to ArcGIS Online
Sharing Tile Package to ArcGIS Online
This tool has similar parameters to the Share as Web Layer parameter used when sharing feature classes - You select the input, summary, tags, and credits.
The credits that are shown in the image are taken from the LINZ Website under the 'Licensing and using data' section.
When you run the Share Package tool, the Tile Package is uploaded to ArcGIS Online. You can also choose to publish the Tile Package as a web Tile Layer in addition - this is recommended. The final two tickboxes allow you to set the sharing settings before uploading the layer.
Once you have exported the tile layer into a tile package (tlpk), It will be ready to share to ArcGIS Online using the 'Share Package' tool.
Other Considerations
Once the tile package has been uploaded you can define the minimum and maximum scale at which the layer is visible in the Settings tab of the item. When tiles are not available, the layer will be drawn by resampling the existing tiles. Set the slider to the minimum and maximum scales at which you would like your layer to be visible. See the image below.
Slider to set Visible range for the Hosted tile layer
Once you have updated the resampling settings, you can use the tiled layer as a basemap. In ArcGIS Online, this can be done in Map Viewer by clicking on the Basemap icon in the dark toolbar on the left, selecting 'Current Basemap', and then adding the hosted tile layer.