OruxMaps
Visit the new forum: <a href="http://www.oruxmaps.com/foro">OruxMaps</a>

Join the forum, it's quick and easy

OruxMaps
Visit the new forum: <a href="http://www.oruxmaps.com/foro">OruxMaps</a>
OruxMaps
Would you like to react to this message? Create an account in a few clicks or log in to continue.

MultiLayer map with different tile sizes on different layers

2 posters

Go down

MultiLayer map with different tile sizes on different layers Empty MultiLayer map with different tile sizes on different layers

Post  janek_schumann Sun Apr 29, 2012 12:21 pm

Hey Orux,


First off: great app! I love it!

I'm writing here since I have a large Map (1.5 GB+) and OruxDesktop can not convert it. I guess it tries to load the complete image into memory instead of using a stream based approach. 8 GB are not enough, I guess...

So my idea was to create the tile database myself and just use OruxDesktop to get the XML file for calibration.

Works pretty well so far, except I ran into an issue when generating multi-layer maps. For every layer there is an img_width and img_height attribute in the XML.
What I wanted to do is to use 512x512 tiles for all layers except level 12. Here I use 256x256 tiles.

The problem:
OruxMaps now uses 256x256 for ALL layers, not only for the last one in the file (level 12). Messes up the map pretty good on all other level, except level 12.

Is that a bug or a feature? Smile

---

side note: Which tile size would you suggest? 128, 256 or 512?

janek_schumann

Cantidad de envíos : 2
Fecha de inscripción : 2012-04-29

Back to top Go down

MultiLayer map with different tile sizes on different layers Empty Re: MultiLayer map with different tile sizes on different layers

Post  orux Wed May 02, 2012 2:05 pm

janek_schumann wrote:Hey Orux,


First off: great app! I love it!

I'm writing here since I have a large Map (1.5 GB+) and OruxDesktop can not convert it. I guess it tries to load the complete image into memory instead of using a stream based approach. 8 GB are not enough, I guess...

So my idea was to create the tile database myself and just use OruxDesktop to get the XML file for calibration.

Works pretty well so far, except I ran into an issue when generating multi-layer maps. For every layer there is an img_width and img_height attribute in the XML.
What I wanted to do is to use 512x512 tiles for all layers except level 12. Here I use 256x256 tiles.

The problem:
OruxMaps now uses 256x256 for ALL layers, not only for the last one in the file (level 12). Messes up the map pretty good on all other level, except level 12.

Is that a bug or a feature? Smile

---

side note: Which tile size would you suggest? 128, 256 or 512?


Hello,

OMD tries to read the images in strips, but the java support for image processing is not very good, I have to search other libraries.

Sorry, but you can not mix different tile sizes in the same map.

256 or 512 give a good result.

orux
orux
orux

Cantidad de envíos : 3946
Fecha de inscripción : 2009-07-06

Back to top Go down

MultiLayer map with different tile sizes on different layers Empty Re: MultiLayer map with different tile sizes on different layers

Post  janek_schumann Wed May 02, 2012 5:23 pm

Here is what I did to get my final solution:


  • exported every level / layer with OziMapTrans to one single png file + map file for calibration
  • calibration:

    • converted each map file to ortk2
    • copied the content of every ortk2 file into one single file
    • modified tile size and tiles count

  • tiles

    • used PngCs (C# port of PngJ) to read and write PNGs line by line
    • used tile size of 128x128
    • processed every level / layer separately (created a SQLite database for each)
    • merged all databases together in the end



as a result I got a ~2 GB database with level 9-16 for the complete alps. Works wonders. Tested it yesterday in the field and I can't see any performance issues with it. (old smartphone with only 600Mhz and 150MB RAM! Smile ) Calibration is also very impressive. (lets say 2-5 "pixels" around the real position on the map is waaayyyy within the noise level of the built-in GPS receiver! so absolutely no complaints here. Smile )

Next step:
writing a program to create maps directly from canadian geodata services (they have really good and free material which is very easy to process).
After that, I'm all set for my next expedition to the rockies! hurray! bounce


My wishlist for the future:
Layers, layers, layers and more layers. (e.g. layer for altitude lines, roads, POIs, summits, huts, ...)


BTW: I *love* the photo-waypoint-function! Smile

janek_schumann

Cantidad de envíos : 2
Fecha de inscripción : 2012-04-29

Back to top Go down

MultiLayer map with different tile sizes on different layers Empty Re: MultiLayer map with different tile sizes on different layers

Post  Sponsored content


Sponsored content


Back to top Go down

Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum