Hot answers tagged

68

The WMS standard allows the client to request an arbitrary region. If the client wants tiles, it can makes its requests in a tiled pattern, but the server has no way to know that's what's happening and if the server stores the map as tiles of its own, it has no way to let the client know what the tile arrangement is. OSGeo came up with two ways to deal ...


43

A WMTS delivers tiles (mostly 256x256 pixel size), while WMS delivers one image per request. Main advantage of tiles is that they can be pre-renderd on the server side, and cached on the client side. This will reduce waiting time for the data and bandwith. On the other hand, you need lots of Gigabytes if you want to pre-render the whole world. Most of it ...


21

The OSM wiki page is perfect : http://wiki.openstreetmap.org/wiki/Slippy_map_tilenames#Lon..2Flat._to_tile_numbers_2 Here is the extracted answer (in pseudo code) for quick reference. Given Longitude/latitude/zoom to tile numbers : n = 2 ^ zoom xtile = n * ((lon_deg + 180) / 360) ytile = n * (1 - (log(tan(lat_rad) + sec(lat_rad)) / π)) / 2 Note that log(...


13

By the looks of it you render the QGIS WMTS in a different projection than the original WMTS. This can be seen by the angle of intersection of the highways. In QGIS this seem to be a perfect 90 degree angle, in the browser it is not. The reprojecting is done locally in QGIS, not at the server side. Therefore the original image gets distorted resulting in the ...


11

WMTS assumes a DPI 90.7 instead of 96 as is clearly documented in the WMTSCapabilities document which states, "The tile matrix set that has scale values calculated based on the dpi defined by OGC specification (dpi assumes 0.28mm as the physical distance of a pixel)." 0.28 mm per pixel = 0.0110236 inches per pixel or 90.71446714322 pixels per inch. ...


11

The zoomscales in QGIS probably differ from the configured grid set in GeoServer. This causes resampling of the images in QGIS resulting in less sharp images and less performance. See GeoServer documentation. You can change the zoomscales in QGIS via: Settings Options Map Tools Predefined zoomscales Different sets I use are: (Copy paste to XML, then ...


10

Set your Project CRS to a relevant CRS (e.g. EPSG:6870) and/or enable OTF. In the WMS Connection Details, check the Ignore axis orientation (WMS 1.3/WMTS) option: Then add the layers of interest:


8

After some experiments I found out that the core of this problem is related to the predefined scale levels QGIS uses. Through the slider provided at View > Panels > Tile Scales I could gather more information about the WMTS-Scale Levels the Basemap.at WMTS scales at. As a next step i went to Settings > Options > Map Tools and replaced the scales which are ...


8

I was able to get it to work using this for the url: http://albmaps.asig.gov.al/service/ows? Hopefully this will work for you. edit - Joseph's answer worked for me too.


6

I've found problem by myself at the end. The reason why it didn't work is because my tiles were created using gdal2tiles and they were created using TMS scheme while examples at http://tileserver.maptiler.com/#nasa/ol3 works only for tiles generated using MapTiler which renders tiles following XYZ schema. Difference between those 2 types is well explained ...


6

It seems that all WMTS service that were suspicious in my question, were right; I was wrong. World of CRS definitions is not so simple. Actual axis order to be used while constructing TopLeftCorner, results from CRS definition. It has been explained e.g. at http://www.geotoolkit.org/modules/referencing/faq.html#axisOrder. For CRS like EPSG:3857, EPSG:...


6

You can try the ArcGIS QMS plugin (ArcQMS). See https://my.nextgis.com/downloads/software/arcqms/ArcQMSInstaller.msi More information see here: https://qms.nextgis.com/about http://nextgis.com/blog/qms-service/


6

It seems there is no easy way to do this in QGis, so I solved it by adding a simple proxy, Python Logging Proxy which "does what it says on the can". I modified the file LoggingProxyHTTPHandler.py to comment out line 105 print response.content since I didn't need to see the "contents" of the images being sent back. Then to run the proxy all you do is ...


6

This specific WMTS source has a small problem: not all reported scales have available tiles. If you look at the capabilities document, the TileMatrix has 22 scales available (up to level 21) for the layer Photographies aériennes. QGIS will try to fetch tiles up to the level 21. That is what you have in the capabilities document. If you install the QGIS ...


5

You could play around with the Resampling options in Layer Properties > Style > Resampling. I did a quick test and got the map to be a bit sharper by applying the following changes:


5

In QGIS 2.2.0 you can use the Add WMS/WMTS Layer menu option directly; then when you create a new connection you need to supply the url to the WMTS capabilities document. When you connect to your WMTS, you then select the Tilesets tab option and select the layer you want to use.


5

I think the issue you had was because Lantmäteriet is using SWEREF 99/EPSG:3006 projection and Leaflet is using EPSG:3857. My solution was to use proj4leaflet to transform between those projections, like this: import L from 'leaflet'; import { CRS } from 'proj4leaflet'; const apiKey = process.env.LANTMATERIET_TOKEN; // This is the important task, where we ...


5

Using a tiled web service allows you to pre-render the tiles. This will make accessing them later on very fast. It works best if the data does not change but if, then GeoServer would simply re-render them appropriately. GeoServer comes with GeoWebCache which makes this easy to setup and initialise.


5

Ok some more digging with other keywords gave me the solution: QGIS 2.4: Basemap.at is displayed in poor quality It's related to the scale of layer in viewport. There's a plugin called "Tile map scale" which helps put map in to scale that provides best quality. You can also change qgis scales in map setting to values that ensure proper rendering.


4

Technically wmts could be use as a tilelayer, but will have to figure out your Tiling structure. A constructor for a layer could look something like this: L.tileLayer('<ServiceRoot>?SERVICE=WMTS&REQUEST=GetTile&VERSION=[version]&Layer=[layername]&Format=image/png&TileMatrixSet[MatrixsetName]=&TileMatrix={z}&TileRow={x}&...


4

Not directly - if you use the GeoWebCache extension (which is built in by default) then you can serve WMTS 1.0.0. and TMS 1.0.0.


4

I have tried your WMTS in QGIS 2.8.1 (64-bit install on Win8.1) and for me it loads without problems. The layers load within 30 seconds. When using zoom to layer, the layers are however only showing as small object in the middle of the screen. They are not zoomed to the full extend of the map viewer. When zooming further in manually the layers show up on the ...


4

The default geoserver (geo web cache) WMTS is available at http://myserver.com:8080/geoserver/gwc/service/wmts?request=getcapabilities . I suspect you need to use a url similar to this to get the capabilities document and then check that your code matches the parameters advertised there.


4

When this happens to me, it's usually one of the following: try "zoom to content" on the layer, to adjust your bounding box check, if your CRS in QGIS matches the one, you load from the WMS try zooming in, as layers may have a styling rule to be only shown at a certain zoom level EDIT: Took a further look at the service and tried to get plain tiles but ...


4

You are probably mixing up a tutorial for the OpenGeo Suite with an official GeoServer (the suite contains a modified one, different style, extra non default plugins, don't know if there are other changes). It seems you are trying to get vector tiles going, in the official GeoServer that's an unsupported module that you can download from the nightly builds: ...


4

I made a jsfiddle to give you an example of how to create a L.tileLayer from your GetCapabilities document. It's a quick mockup and could be improved a lot (absolutely no error handling, XML search is rather naive etc.), but gives you an idea about how to get going. Note: you can use a layer name of your choice, but there is no further dynamics in creating ...


4

The return type of a GetCapabilities document from a WMS/WMTS service should always be an application specific one of application/vnd.ogc.wms_xml due to there not being a well defined standard mime type when the specification was written. You can confirm this by using curl to inspect the headers. HTTP/1.1 200 OK Server: Apache-Coyote/1.1 X-Frame-Options: ...


4

If you're okay to write a NodeJS script you can use const request = require('request'); const VectorTile = require('@mapbox/vector-tile').VectorTile; const Pbf = require('pbf'); const zlib = require('zlib'); request({ url: 'https://example.com/1/2/3.pbf', encoding: null }, (err, response, body) => { try { body = zlib.gunzipSync(...


4

The data is likely served using the projection EPSG:3857 and your project is likely using a different projection, so the images are re-projected - and therefore distorted. Try changing the project projection by clicking on it in the lower right of the QGIS window


3

If you want to get a 256*256 PNG tile of a certain map service from geoserver you can do it with including tiled=TRUE in your request: http://localhost:8080/geoserver/wms?LAYERS=spearfish&STYLES=&FORMAT=image%2Fpng&TILED=true&TILESORIGIN=589425.93423656%2C4913959.2246118&SERVICE=WMS&VERSION=1.1.1&REQUEST=GetMap&SRS=EPSG%...


Only top voted, non community-wiki answers of a minimum length are eligible