Difference between TileWMS and WMTS in openlayers 3? - openlayers-3

Whats the difference between ol.source.TileWMS and ol.source.WMTS? As of i know if tiled = true is added in WMS url both will return Tiled Images in openlayers 3.
Thanks in advance.

The OpenLayers documentation says:
An ol.source.TileWMS loads tile data from WMS servers.
An ol.source.WMTS loads tile data from WMTS servers.
A WMS serves images which are generated on-the-fly, whilst a WMTS serves tiles which are pre-rendered and cached.
The advantage of the latter is that you achieve better performance, but it also requires storage space.
Check out this answer also:
Difference between WMTS and WMS

Related

How to add tiles layer on map using MapBox in Swift (iOS mobile app)

I want to set WMS tiles layer on the map using MapBox in my iPhone app.
Note: I am able to add tiles layer at Google Map using provided methods at https://developers.google.com/maps/documentation/ios-sdk/tiles.
Now I am trying to add WMS tiles layer in MapBox but I am not able to get any method to add WMS tiles layer at the map.
If there is any way to set tiles layer in MapBox. Please let me know.
Thanks in advance.
I recently had need of this for a project myself, and found this to be a very poorly documented part of the Mapbox iOS SDK. Have a look over on this page: https://github.com/mapbox/mapbox-gl-native/blob/master/platform/ios/docs/guides/Tile%20URL%20Templates.md.
You can use {bbox-epsg-3857} as a placeholder in your URL templates. The rest of the URL format will be all your standard WMS junk like version, request, format, etc. For the WIDTH and HEIGHT, use 256.

Software to open titled geo PNG file?

I'm trying to extract some a data (a map image) from a PNG file which is tiled somehow. The file itself is only 256x256 pixels (according to 'get info' on the mac) but is is 23MB. It is from an iPad app called Mud Map and it contains a map that I purchased but I've lost the original that I converted to this format. When I view this file (renamed to a .PNG) I see one section of the map - 256x256px.
I'm asking this question on StackOverflow because I want to know more about these tiled images. How does one create a tiled PNG and what is the software that will open and or create these things. I'm interested in what metadata is required too. I'm loving the outdoors and mapping!!
The answer to this question, is that it cannot be done in manner I have described.
The images in the PNG are not tiled, the the files are just merged together which is no doubt an individual feature of the program as is it does not appear to be any kind of standard.
I have no access to application you mentioned in IPad. Just share some thought about possible situation here.
1) Map tiles are commonly used in GIS web application such as Google maps and so on. It is used to improve the performance especially when user pan very often. A map displayed typical map window is divided into for instance 4*4 separate calls. So maybe only 4 call will be made when user just pan a little bit instead of get the whole map for the 16 tiles.
The source image for this tiles can be in pre-generated tiles or just one static map.
2) Assemble separate images to one in GIS is called image mosaic function. GIS server can read a collection of images and mosaiced them into one with the overlapping part handle based on a certain rule. And the images are in pre defined grid format which are seamless and no overlapping, then it is called tiled images. We could pre-generated the tiles from one mosaiced image, or we can server it on the fly. Some GIS server/library/application does have the tile server function built in.

Generate Tiles with GDAL

I want to generate different raster according to scale like Google Maps with gdal tool GDAL2TILES for my WEB GIS who run with OL3. For example,
scale 1 :
and the same place Scale 2 :
What you are looking for is a tile server to seeding the tiles for your openlayers application to consume. And the different image output at different zoom level in the same location is called raster pyramid.
http://webhelp.esri.com/arcgisdesktop/9.3/index.cfm?TopicName=Raster_pyramids
Back to your question, if you want to generate tiles, there are multiple solutions out there, many free open sourced ones are build based on GDAL as you mentioned such as GeoWebCache, MapProxy, etc.
You can seed/replace tile image at different zoom level to generate your own raster pyramids. And then you can either consume the Tile map service, or directly access the tiles via OpenLayers.

Skobbler map clustering

I'm trying to figure out how I can use pin clustering with SKMapView and SKAnnotation?I see that there is SKPOICluster, but I'm not sure there is a way to Use it with SKAnnotation.
Unfortunately there is no clustering support for SKAnnotations (you will have to implement yourself the logic for choosing which annotations are visible at each zoom level).
Note: clustering support for SKAnnotations is work in progress
The SKPoiCluster is to be used with SKMapPoi. (SKMapPoi offers clustering support) The tradeoff for SKMapPoi is that the icons that can be used are rather limited - sprites from a png file, so if you want to modify an icon you need to modify the png file.

iOS: Using vector data in MKOverlay in MapKit

I'd like to overlay a custom map using MapKit. I've currently implemented the TileMap sample from WWDC10. However, my overlay map is in vector form (pdf) and it seems like a terrible waste to rasterise it and convert it to tiles (also takes up about 10megs as opposed to 300KB).
Is there a way to either:
a) overlay a pdf using MKOverlay, or
b) easily convert a vector graphic into MKPolygons, lines etc., so I can recreate my overlay map in MapKit?
Notes: The map I'm trying to overlay is pretty simple but geographically huge. It does need to work offline.
You can overlay a PDF using MKOverlay. In the drawMapRect:zoomScale:inContext: method of your MKOverlayView just use standard PDF drawing functions. You can find those functions here.
The problem with this approach is that for each maprect that is sent to that drawing method you will have to draw the entire PDF each time. This will be really slow. I think you will see the best performance by rasterizing the PDF and converting it to tiles. 10 MB is not too large of a dataset to ship with an iOS app.

Resources