Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

The maps are provided from the OS via Web Mapping Tile Services (WMTS) from https://api.os.uk. To use these services a key must be generated. Follow the guidance here from the Ordnance Survey.

MapProxy

...

Configuration

iShare v6 uses MapProxy to cache requests to the OS WMTS. Configuration of MapProxy is done by editing the mapproxy.yaml configuration file.

...

Save the following as “E:\iShareData\LIVE\_MapServerConfig\base_osmapapi.map” if creating base maps for iShare LIVE or “E:\iShareData\TEST\_MapServerConfig\base_osmapapi.map” if creating base maps for iShare TEST. You will notice the .map file has no layer definitions. It is only used to select the base map’s projection.

Code Block
MAP
	NAME "OS MAP API"
	CONFIG "PROJ_LIB" "D:\mapserver\shared\proj\nad"
	CONFIG "MS_ERRORFILE" "logs/live_base_osmapapi_debug.log"
	PROJECTION
		"init=epsg:27700"
	END
	TEMPLATEPATTERN "."
	MAXSIZE 8192
	SIZE 512 512
	EXTENT 0 0 700000 1300000
	IMAGECOLOR 238 238 237
	DEBUG 5
	FONTSET "D:/mapserver/shared/fonts/fonts.list"
	SYMBOLSET "D:/mapserver/shared/symbols/symbolsms6.sym"
	SHAPEPATH "../"
	IMAGETYPE "png"
	OUTPUTFORMAT
		NAME "png"
		DRIVER "AGG/PNG"
		IMAGEMODE RGB
		MIMETYPE "image/png"
		EXTENSION "png"
		TRANSPARENT FALSE
		FORMATOPTION "INTERLACE=OFF"
		FORMATOPTION "QUANTIZE_FORCE=ON"
	END
	UNITS METERS
	RESOLUTION 72
	WEB
		METADATA
			"ows_title" "OS MAPS API" 
			"author" "Astun Technology" 
			"ows_enable_request" "*" 
			"ows_srs" "EPSG:27700" ## Recommended
			"ows_abstract" "OS MAPS API Demonstration" 
			"wms_srs" "epsg:27700"
		END
		IMAGEPATH "D:/mapserver/tmp/"
		TEMPPATH "D:/mapserver/tmp/"
		IMAGEURL ""
		TEMPLATE "globexml.xml"
	END
END

Create

...

Base Maps in Studio

Create a new base map in Studio under Map Sources > BaseMaps.

...