[Qgis-user] Fwd: GDAL2tiles in local crs in QGIS

Marco Bernasocchi marco at opengis.ch
Thu Jan 14 01:07:02 PST 2021


Hi all,
just a short/probably stupid question that I'm loosing way too much time on
already :)

is there a way to have gdal2tiles create tiles in a local crs (for example
EPSG:2056) and load them into QGIS?
I'm doing
gdal2tiles.py --profile=raster --zoom=0-5 --s_srs=EPSG:2056
CH_over_2000_lv95.tif test_tiles

and it looks like the resulting tilemapresource.xml and the openlayers
example are correct, but loading them in QGIS using

file:///home/marco/gis/test_tiles/{z}/{x}/{y}.png

I get a wrong placement (crs of the tiles is set to 3857, which is
"workaroundable") and wrong tiles alignment (looks like 0,0 top left vs 0,0
bottom left).

I know the TMS "standard" is old but it would still be nice to be able to
quickly take a tiff, chop it up in tiles and use it in QGIS. And using
--xyz parameter results in correct tiles but in 3857

Am I doing something stupidly wrong :) ? or is WMTS really the only way to
have tiles in local crs?

Cheers
Marco


-- 
Marco Bernasocchi
OPENGIS.ch CEO
QGIS.org Chair

Find a meeting time on my calendar <https://calendly.com/mbernasocchi/30min>
!
marco at opengis.ch
+41 (0)79 467 24 70 <+41794672470>

<https://opengis.ch>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-user/attachments/20210114/eef2a9b3/attachment.html>


More information about the Qgis-user mailing list