Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - jurajs

Pages: [1]
1
Discussion/New features / forum quota exceeded ?
« on: May 19, 2012, 12:38:33 »
hmmm ... i was just trying to attach cca 50kb file here... what is the problem ? is the quota somehow counted altogether among all my posts ? in that case i need more ;-)

2
Tools / [TOOL] guide to creating .poly files easily
« on: May 03, 2012, 20:21:43 »
Hi there

does anyone have experience with creating .poly files (those used with osmosis) ?
all the sources of polygon files out there are not suitable enough for me. i want to do it by myself, but creating it manually is really annoying and time consuming. :-(

simple "by-mouse click-clack way" graphical tool is prefered. (if you know what i mean ... nak-nak)

any ideas are welcome


*EDIT: renamed subject from [wanted] to [TOOL]

3
Themes - Vector maps / [Theme] only_contours
« on: May 02, 2012, 20:22:42 »
only_contours

this theme needs special maps generated with contour lines data like these: viewtopic.php?f=43&t=1839. theme renders only contour lines /black on white/ and captions with altitude every 100 meters.

howto:
- extract "only_contours.zip" into ".../Locus/mapsVector/_themes/"
- activate theme in locus in "Settings / Map - advanced / Theme of the maps"

maps and guide available here:
viewtopic.php?f=43&t=1839

@menion - feel free to publish in locus shop

4
Themes - Vector maps / [Theme] Hiking v0.6
« on: May 01, 2012, 02:26:47 »
hiking map theme

this theme is massively inspired by hiking maps from http://http://www.freemap.sk and supposed to render in very similar way.
latest version: 0.6 (available here: viewtopic.php?f=40&t=1871#p12497)

main features:
- handy for outdoor activities like hiking, cycling, etc...
- supports maps with terrain contour lines  (http://forum.asamm.cz/viewtopic.php?f=43&t=1839)
- some new patterns
- rendering order changed slighty (tunnels, military area, etc...)
- landuse rendering is more fancy (more colors)

howto:
- extract "hiking.zip" into ".../Locus/mapsVector/_themes/"
- activate theme in locus in "Settings / Map - advanced / Theme of the maps"

maps with terrain contour lines available here:
http://forum.asamm.cz/viewtopic.php?f=43&t=1839

@menion - feel free to publish in locus shop

5
Themes - Vector maps / [Theme] osmarender + terrain contours rules
« on: April 26, 2012, 00:04:13 »
osmarender_terrain

this theme is same as original osmarender theme... with added rules needed to display terrain contour lines. can be used with any regular vector map, but was mainly created to work with special vector maps which contains also terrain contours.

howto:
- extract "osmarender_terrain.zip" into ".../Locus/mapsVector/_themes/"
- activate theme in locus in "Settings / Map - advanced / Theme of the maps"

maps and guide available here:
http://http://forum.asamm.cz/viewtopic.php?f=43&t=1839

@menion - feel free to publish in locus shop

6
Maps / [MAPS] - Vector maps (with terrain contour lines)
« on: April 22, 2012, 16:04:18 »
Quote
Maps for download presented in this post are rarely updated these days, because i became too lame to keep them fresh. :) But don't get upset. You can still find many interesting information, guides, hints and hopefully also latest news in this thread.

For regulary updated vector maps you can:
-  buy them in locus shop directly or also
-  download maps for free from openandromaps.org
(don't forget to buy a beer to kech61, he is doing great job).

Hi there.

Just to use these maps you will need:
- render theme(s) that supports elevation tags (e.g. http://forum.asamm.cz/viewtopic.php?f=40&t=1871)
- vector map made with elevation data (e.g. some maps are available at the bottom of this post in "Maps for download" section)
- thats it !

Short description:
- here I describe briefly how to make mapsforge vector map(s) using original osm data along with srtm terrain elevation data. Final map tiles will be generated also with fancy terrain contour lines.
- i will share here also download links for some maps, so you can test/use it by yourself
- there are also themes available (read below)

Themes supporting these maps:
. [Theme] osmarender + terrain contours rules <!-- m -->http://forum.asamm.cz/viewtopic.php?f=40&t=1853<!-- m -->
- [Theme] Volatile <!-- m -->http://forum.asamm.cz/viewtopic.php?f=40&t=1868<!-- m -->
- [Theme] Hiking <!-- m -->http://forum.asamm.cz/viewtopic.php?f=40&t=1871<!-- m -->
- [Theme] only_contours <!-- m -->http://forum.asamm.cz/viewtopic.php?f=40&t=1894<!-- m -->

Guide to make your own map (v0.4_2012-05-08):
As an example i will write here how I managed to create a map of Slovakia as this was my really first more or less successfull attempt <!-- s;-) -->;-)<!-- s;-) -->

1. download and install osmosis, phyghtmap, mapsforge mapwriter plugin, srtmfill. get some osm map data from e.g. osm/cloudmade/geofabrik including polygon files, but I preffer my own "handmade" polygons with the smallest complexity possible for better processing speeds.
(computing time increases rapidly with complexity of polygon files, i don't recommend using files with size > 5KB)

2. download "tag-mapping.xml" and add there these lines. (needed for mapwriter)
Code: [Select]
   <!-- Elevation TAGS -->
   <ways>
      <osm-tag key="contour_ext" value="elevation_minor" zoom-appear="12" force-polygon-line="true" />
      <osm-tag key="contour_ext" value="elevation_medium" zoom-appear="12" force-polygon-line="true" />
      <osm-tag key="contour_ext" value="elevation_major" zoom-appear="12" force-polygon-line="true" />
      <osm-tag key="ele" value="100" zoom-appear="14" />
      <osm-tag key="ele" value="200" zoom-appear="14" />
      <osm-tag key="ele" value="300" zoom-appear="14" />
      <osm-tag key="ele" value="400" zoom-appear="14" />
      <osm-tag key="ele" value="500" zoom-appear="14" />
      <osm-tag key="ele" value="600" zoom-appear="14" />
      <osm-tag key="ele" value="700" zoom-appear="14" />
      <osm-tag key="ele" value="800" zoom-appear="14" />
      <osm-tag key="ele" value="900" zoom-appear="14" />
      <osm-tag key="ele" value="1000" zoom-appear="14" />
      <osm-tag key="ele" value="1100" zoom-appear="14" />
      <osm-tag key="ele" value="1200" zoom-appear="14" />
      <osm-tag key="ele" value="1300" zoom-appear="14" />
      <osm-tag key="ele" value="1400" zoom-appear="14" />
      <osm-tag key="ele" value="1500" zoom-appear="14" />
      <osm-tag key="ele" value="1600" zoom-appear="14" />
      <osm-tag key="ele" value="1700" zoom-appear="14" />
      <osm-tag key="ele" value="1800" zoom-appear="14" />
      <osm-tag key="ele" value="1900" zoom-appear="14" />
      <osm-tag key="ele" value="2000" zoom-appear="14" />
      <osm-tag key="ele" value="2100" zoom-appear="14" />
      <osm-tag key="ele" value="2200" zoom-appear="14" />
      <osm-tag key="ele" value="2300" zoom-appear="14" />
      <osm-tag key="ele" value="2400" zoom-appear="14" />
      <osm-tag key="ele" value="2500" zoom-appear="14" />
      <osm-tag key="ele" value="2600" zoom-appear="14" />
      <osm-tag key="ele" value="2700" zoom-appear="14" />
      <osm-tag key="ele" value="2800" zoom-appear="14" />
      <osm-tag key="ele" value="2900" zoom-appear="14" />
      <osm-tag key="ele" value="3000" zoom-appear="14" />
      <osm-tag key="ele" value="3100" zoom-appear="14" />
      <osm-tag key="ele" value="3200" zoom-appear="14" />
      <osm-tag key="ele" value="3300" zoom-appear="14" />
      <osm-tag key="ele" value="3400" zoom-appear="14" />
      <osm-tag key="ele" value="3500" zoom-appear="14" />
      <osm-tag key="ele" value="3600" zoom-appear="14" />
      <osm-tag key="ele" value="3700" zoom-appear="14" />
      <osm-tag key="ele" value="3800" zoom-appear="14" />
      <osm-tag key="ele" value="3900" zoom-appear="14" />
      <osm-tag key="ele" value="4000" zoom-appear="14" />
      <osm-tag key="ele" value="4100" zoom-appear="14" />
      <osm-tag key="ele" value="4200" zoom-appear="14" />
      <osm-tag key="ele" value="4300" zoom-appear="14" />
      <osm-tag key="ele" value="4400" zoom-appear="14" />
      <osm-tag key="ele" value="4500" zoom-appear="14" />
      <osm-tag key="ele" value="4600" zoom-appear="14" />
      <osm-tag key="ele" value="4700" zoom-appear="14" />
      <osm-tag key="ele" value="4800" zoom-appear="14" />
      <osm-tag key="ele" value="4900" zoom-appear="14" />
      <osm-tag key="ele" value="5000" zoom-appear="14" />
       <!-- .... etc ....  -->
   </ways> 

3. [you can skip this by downloading suitable theme]
use rendertheme of your choice and edit rule file ".xml". Add the following code just before waterways section. This edited file use as rendering theme for vector maps in your locus in order to display also terrain contour lines.
Code: [Select]

        <!-- contour lines level 12 -->
        <rule e="way" k="contour_ext" v="*" zoom-min="12" zoom-max="12">
           <rule e="way" k="contour_ext" v="elevation_minor">   
              <line stroke="#60800000" stroke-width="0.3"/>
           </rule>
           <rule e="way" k="contour_ext" v="elevation_medium|elevation_major">   
              <line stroke="#60800000" stroke-width="0.6"/>
           </rule>
        </rule>
        <!-- contour lines level 13 -->
        <rule e="way" k="contour_ext" v="*" zoom-min="13" zoom-max="13">
           <rule e="way" k="contour_ext" v="elevation_minor">   
              <line stroke="#60800000" stroke-width="0.2"/>
           </rule>
           <rule e="way" k="contour_ext" v="elevation_medium|elevation_major">   
              <line stroke="#60800000" stroke-width="0.5"/>
           </rule>
        </rule>
        <!-- contour lines level 14-->
        <rule e="way" k="contour_ext" v="*" zoom-min="14" zoom-max="14">
           <rule e="way" k="contour_ext" v="elevation_minor">   
              <line stroke="#60800000" stroke-width="0.15"/>
           </rule>
           <rule e="way" k="contour_ext" v="elevation_medium|elevation_major">   
              <line stroke="#60800000" stroke-width="0.4"/>
              <rule e="way" k="*" v="*">
                 <pathText k="ele" font-style="bold" font-size="10" fill="#000000" stroke="#ffffff" stroke-width="2.0" />
              </rule>  
           </rule>   
        </rule>
        <!-- contour lines level 15-->
        <rule e="way" k="contour_ext" v="*" zoom-min="15" zoom-max="15">
           <rule e="way" k="contour_ext" v="elevation_minor" zoom-max="15">   
              <line stroke="#60800000" stroke-width="0.12"/>
           </rule>
           <rule e="way" k="contour_ext" v="elevation_medium|elevation_major">   
              <line stroke="#60800000" stroke-width="0.3"/>
              <rule e="way" k="*" v="*">
                 <pathText k="ele" font-style="bold" font-size="10" fill="#000000" stroke="#ffffff" stroke-width="2.0" />
              </rule>
           </rule>
        </rule>
        <!-- contour lines level 16 -->
        <rule e="way" k="contour_ext" v="*" zoom-min="16" zoom-max="16">
           <rule e="way" k="contour_ext" v="elevation_minor">   
              <line stroke="#60800000" stroke-width="0.08"/>
           </rule>
           <rule e="way" k="contour_ext" v="elevation_medium|elevation_major">   
              <line stroke="#60800000" stroke-width="0.2"/>
              <rule e="way" k="*" v="*">
                 <pathText k="ele" font-style="bold" font-size="10" fill="#000000" stroke="#ffffff" stroke-width="2.0" />
              </rule>
           </rule>
        </rule>   
        <!-- contour lines level 17 and above -->
        <rule e="way" k="contour_ext" v="*" zoom-min="17">
           <rule e="way" k="contour_ext" v="elevation_minor">   
              <line stroke="#60800000" stroke-width="0.06"/>
           </rule>
           <rule e="way" k="contour_ext" v="elevation_medium|elevation_major">   
              <line stroke="#60800000" stroke-width="0.15"/>
              <rule e="way" k="*" v="*">
                 <pathText k="ele" font-style="bold" font-size="10" fill="#000000" stroke="#ffffff" stroke-width="2.0" />
              </rule>
           </rule>
        </rule>

4. if you have prepared your environment correctly, run these commands, and you should end-up with map file created.

4.1 download and process the terrain data.
Code: [Select]
C:Python27Scriptsphyghtmap --polygon=E:OSMpolygonsslovakia.poly -o E:OSMsrtm-dataslovakia_srtm6 --source=view1,view3,srtm1,srtm3  -s 20 -c 200,100 --start-node-id=20000000000 --start-way-id=10000000000 --write-timestamp --max-nodes-per-tile=0
4.1.1 [highly recommended] after the pyghtmap has downloaded hgt elevation data, you can kill phyghtmap and use srtmfill utility to fix "null" data in hgt files (I had a lot of null/invalid data so i had to fix them all). before proceeding to next step you have to run phyghtmap command again so the osm file will be created from valid elevation data.

4.1.2 [better speed - not recommended] instead of --polygon option you can use -a in this step and cut the map polygon in next step with osmosis (processed in few seconds/minutes, but the result quality is worse).

4.1.3 [optional] you can cut-out the map area corresponding with polygon file used for processing the terrain data
Code: [Select]
osmosis --rx e:OSMosm-map-dataeurope.osm.bz2 --tee 1 --bp file="E:OSMpolygonsslovakia.poly" --wx e:OSMosm-map-dataslovakia.osm
4.2 [optional] sort is essential before merge (merge task is requiring all osm files sorted). proceed with this step for one or both files if you get errors during merge.
Code: [Select]
osmosis --rx e:OSMosm-map-dataslovakia.osm.bz2 --sort --wx e:OSMosm-map-dataslovakia.sorted.osm
4.3 merge both files together
Code: [Select]
osmosis --rx e:OSMosm-map-dataslovakia.sorted.osm --rx E:OSMsrtm-dataslovakia_srtm6.osm --merge --wx e:OSMosm-map-dataslovakia.merged.osm
4.4 create final map using mapsforge mapwriter plugin
Code: [Select]
osmosis --rx e:OSMosm-map-dataslovakia.merged.osm --mw file=e:OSMmapsforgeslovakia.ter.osm.map bbox=47.6,16.7,49.8,22.7 type=hd tag-conf-file=e:OSMtag-mapping.xml
Bugs:
- zoom level 12 and 13 doesn't generate well - probably a bug of mapsforge library (maps published after 8th of May are much better)
- elevation text is more likely displayed at zooms 16-17, but for zooms 14-15 is very rarely visible, although its defined

Maps for download:
(minor contour line steps are 20m, major line steps are 100m)

Europe:
France 2012-05-29 (1095 MB): https://docs.google.com/open?id=0B3Ijv5irWwU7SGh5OWNKaVJsLVE
Germany 2012-09-09 (728 MB): https://docs.google.com/open?id=0B3Ijv5irWwU7X0Y3a0ItNjFjdHc

Europe (Custom regions):
Alps 2012-09-09 (631 MB): https://docs.google.com/open?id=0B3Ijv5irWwU7bGtrNVctNHpSUjA
Austria+Switzerland 2012-09-09 (309 MB): https://docs.google.com/open?id=0B3Ijv5irWwU7SHFpNFlNYjRkVW8
Baltic states (EE,LT,LV+Kaliningrad) 2012-09-09 (77 MB): https://docs.google.com/open?id=0B5YCQIJNF5XhYjFsQXJPa1oxeU0
BeNeLux 2012-09-09 (369 MB): https://docs.google.com/open?id=0B3Ijv5irWwU7d3liM2dGMDR0TjQ
former Yugoslavia (SI,HR,SRB,BiH,MN,MC) 2012-09-09 (192 MB) https://docs.google.com/open?id=0B3Ijv5irWwU7NndLamVnM1ExUVE
Greece, Albania, Cyprus 2012-09-09 (146 MB) https://docs.google.com/open?id=0B5YCQIJNF5XhUXd0aFBpd1BKN2M
Iberian peninsula (ES,PT,AD,GI) + isles 2012-09-09 (387 MB): https://docs.google.com/open?id=0B3Ijv5irWwU7OUQ5ZHhwUmZkV3c
Italy + Malta 2012-09-09 (408 MB): https://docs.google.com/open?id=0B3Ijv5irWwU7LU9KNmNQTk5hb0E
Romania+Bulgaria 2012-09-09 (225 MB): https://docs.google.com/open?id=0B3Ijv5irWwU7T0h2Qkd2bmRVZDg
Scandinavia (DK,NO,FI,SE)  2012-09-09 (689 MB): https://docs.google.com/open?id=0B3Ijv5irWwU7NjFFUG5nLUcwMHc
UK+Ireland+Iceland 2012-09-09 (360 MB): https://docs.google.com/open?id=0B3Ijv5irWwU7TDBsQzhKN1VnTjg
Visegrád Group (CZ,SK,PL,HU) 2012-09-09 (399 MB): https://docs.google.com/open?id=0B5YCQIJNF5XhZjlKQUVvNHNncHc

Asia (Japan):
(Japan-parts.png https://docs.google.com/open?id=0B5YCQIJNF5XhY09oNnJiNmNsMWM)
Hokkaido 2012-05-19 (58 MB): https://docs.google.com/open?id=0B5YCQIJNF5XhblduWDZ3M3pqTDQ
Ryukyu islands and Pacific islands 2012-05-14 (8 MB): https://docs.google.com/open?id=0B5YCQIJNF5XhU2lqaWdVRDNvamc
Honshu 2012-05-?? (??? MB): cancelled...
Shikoku 2012-05-19 (37 MB): https://docs.google.com/open?id=0B5YCQIJNF5XhbmE5MkRWWTFSeVE
Kyushu 2012-05-26 (72 MB): https://docs.google.com/open?id=0B5YCQIJNF5XhY2RhbmFyVVhmVkE

if you are missing something, try to make a wish <!-- s;-) -->;-)<!-- s;-) -->

europe regions maps available for download here are created according to these polygons: 


*** starting from 8th May, new tag-mapping.xml ruleset will be used to create maps***
so you can adjust your themes accordingly. hiking (v0.3) theme will be updated too.
Code: [Select]
<osm-tag key="highway" value="bus_stop" zoom-appear="15" />
<osm-tag key="amenity" value="cafe" zoom-appear="16" />
<osm-tag key="amenity" value="drinking_water" zoom-appear="15" />
<osm-tag key="amenity" value="fast_food" zoom-appear="16" />
<osm-tag key="amenity" value="parking" zoom-appear="16" />
<osm-tag key="amenity" value="pharmacy" zoom-appear="16" />
<osm-tag key="amenity" value="place_of_worship" zoom-appear="15" />
<osm-tag key="amenity" value="pub" zoom-appear="16" />
<osm-tag key="amenity" value="restaurant" zoom-appear="15" />
<osm-tag key="shop" value="supermarket" zoom-appear="15" />
<osm-tag key="railway" value="halt" zoom-appear="15" />
<osm-tag key="railway" value="tram_stop" zoom-appear="15" />
<osm-tag key="tourism" value="alpine_hut" zoom-appear="14" />
<osm-tag key="tourism" value="attraction" zoom-appear="16" />
<osm-tag key="tourism" value="hostel" zoom-appear="15" />
<osm-tag key="tourism" value="hotel" zoom-appear="15" />
<osm-tag key="tourism" value="information" zoom-appear="15" />
<osm-tag key="tourism" value="museum" zoom-appear="16" />
<osm-tag key="tourism" value="viewpoint" zoom-appear="15" />
<osm-tag key="historic" value="memorial" zoom-appear="16" />
<osm-tag key="historic" value="monument" zoom-appear="16" />

see also some screenshots in attachment.
any feedbacks welcome.

Resources used:
http://oruxmaps.foroactivo.net/t2216-co ... xmapsforge (thanks to kech61 for first kick)
http://katze.tfiu.de/projects/phyghtmap/
http://wiki.openstreetmap.org/wiki/Osmarender/Rules
http://wiki.openstreetmap.org/wiki/Srtm2Osm
http://downloads.cloudmade.com/
http://download.geofabrik.de/
http://3dnature.com/srtmfill.html

### this post will be edited from time to time, so please check it sometimes for updates, improvements and fixes ###
last update: 2012-09-09 22:41

7
Hi Menion,

I have seen that you have added an option to change font size for captions in vector maps. Good one.
But I have another idea to improve rendering vector maps.

Can you just add similar possibility to render all symbols and/or captions also on lower/higher zooms to achieve more/less detailed map rendered ?

My intention was to replace all rendertheme strings zoom-min="X" for something like zoom-min="X+/-Y".

What do you think?

Regards,
J.

Pages: [1]