[OpenLayers-Dev] Multiple openlayer protocols
Iván Sánchez Ortega
ivan at sanchezortega.es
Wed Aug 13 06:50:09 PDT 2014
El Miércoles, 13 de agosto de 2014 06:15:25 Kalaivanan escribió:
> Thanks Ivan, I am trying to implement "Spectrum Spatial Tile Service"(SSTS)
> from "MapInfo" web service using openlayer 2.13, is there any JavaScript
> API/plugin available in openlayer?
>From what I can read at
http://reference.mapinfo.com/software/spectrum/lim/8_0/services/index.html ,
and specifically at
http://reference.mapinfo.com/software/spectrum/lim/8_0/services/Spatial/source/Services/map_tiling/rest/tile.html
, the tile service you are referring to takes the form of:
http://{server}/{mapname}/{level}/{x}:{y}/tile.{image type}
Copying and pasting from the examples in those docs:
http://localhost:8080/rest/Spatial/MapTilingService/Samples/NamedTiles/WorldTile/2/1:1/tile.png
If the projections are set to epsg:3857, then it should be quite trivial to
set up an OpenLayers XYZ Layer to fit that scheme, e.g.:
var layer = new OpenLayers.Layer.XYZ(
"Mapinfo Spectrum tiles",
"http://localhost:8080/rest/Spatial/MapTilingService/Samples/NamedTiles/WorldTile/${z}/${x}:
${y}/tile.png"
, { sphericalMercator: true }
);
For a full example on how to set up XYZ layers qith custom URL schemes, see
http://openlayers.org/dev/examples/mapbox.html.
Cheers,
--
Iván Sánchez Ortega <ivan at sanchezortega.es>
More information about the Dev
mailing list