Registered Member
|
Hi,
For an offline application, I need to load some Geotiff maps. I would like to add this Geotiff in a layer in order to superimpose it on the world map. The Geotiff map has a different resolution and has more details. The world map I use comes from http://www.unearthedoutdoors.net/global ... e/download . It is the 2km resolution map (21600 x 10800). It is an Equirectangular projection. The Geotiff I would like to load ant superimpose is in Mercator projection (WGS84 ) at the good position in the world. I don't know really what should I do in order to have the good representation in marble. Should I transform it via GDAL in Equirectangular projection and use gdal2tiles ? Any idea is welcome ! Thanks. |
KDE Developer
|
You could transform it into its own map theme and have Marble do the tiling for you. That's pretty easy to do: Take bluemarble.dgml as a base, adjust things and point it to the download image (png, i don't think Marble can open geotiff) in the installmap tile. Then open that theme in Marble:
Since I did that earlier you can also take my map theme:
Afterwards open Marble and select "True Marble" as map theme. If you want to do the tiling on your own, just delete the 0-4 folders in that archive and put TrueMarble.2km.21600x10800.png in. Marble will do the conversion automatically once the map theme is selected. You'll get a progress dialog during that. Note that it will take some memory (roughly 1 GB), so make sure you have enough RAM. You can also take that layer and use it in other .dgml files and blend other things on top / below. Note that currently blending needs equal tile sizes for each layer. Finally another approach to load tile data would be to use a .kml file and ground overlays. Marble's support for that is still experimental though and not ready yet for large data. |
Registered Member
|
The Geotiff doesn't represent a complete world map but a subregion of the world. So I don't know if your solution works in my case.
|
Registered Member
|
No idea how I could do that ?
May be I should write my own class inheriting from LayerInterface ? (Since TextureLayer is not directly available) |
KDE Developer
|
How large is the area? For smaller ones the KML GroundOverlay solution would work.
|
Registered Member
|
Hi!
I want do the same thing as you. Have you find a solution other than KML/GroudOverlay, please? |
Registered Member
|
Hi,
>>Should I transform it via GDAL in Equirectangular projection and use gdal2tiles ? that is the solution i have used, but transform your GeoTiff into WorldMercator projection, projection parameter: +proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0 +y_0=0 +k=1.0 +units=m +nadgrids=@null +no_defs And i did not use gdal2tiles, i used the gdal lib and coded my own tile creator, the main methode you need is: Gdal::RasterIO(...), unfortunately my solution is not opensource so i could post the code, br,konrad |
Registered users: bancha, Bing [Bot], Evergrowing, Google [Bot], lockheed, mesutakcan, Sogou [Bot]