Fork me on GitHub

OpenSeadragon 5.0.0

example: tile map service support

The Tile Map Service is a tile scheme developed by the Open Source Geospatial Foundation and specified here.

OpenSeadragon supports TMS tile sources thanks to Rainer Simon.

Inline Configuration for Tile Map Services

Inline configuration couldn't be much simpler for using a TMS as a tile source.

Example Inline Configuration for TMS Tile Sources

Configuration is done via the tileSources option (or programatically). Because of its rich levels and depth, we slow down the zoomPerScroll option a little, wrap horizontally, and hide the navigator. Also we set a lower minimum zoom pixel ratio to allow the user to pull back just a little further.

OpenSeadragon({
    id:                 'example-inline-configuration-for-tms',
    prefixUrl:          '/openseadragon/images/',
    showNavigator:      false,
    wrapHorizontal:     true,
    zoomPerScroll:      1.2,
    minZoomImageRatio:  0.5,
    tileSources:   [{
        type:       'tiledmapservice',
        tilesUrl:   'http://tilecache.osgeo.org/wms-c/tilecache.py/1.0.0/basic/',
        width: 256 * 65534,
        height: 256 * 32767
    }]
});