Creating DEM-like maps using TYP customisation

Very nice. Has anyone tried this with mkgmap? http://www.cgpsmapper.com/download/Creating%20custom%20types%20to%20represen... What's needed is to simply (?) convert the contour line to polygon. -- cheers, maning ------------------------------------------------------ "Freedom is still the most radical idea of all" -N.Branden wiki: http://esambale.wikispaces.com/ blog: http://epsg4253.wordpress.com/ ------------------------------------------------------

2009/9/26 maning sambale <emmanuel.sambale@gmail.com>:
Very nice. Has anyone tried this with mkgmap?
http://www.cgpsmapper.com/download/Creating%20custom%20types%20to%20represen...
What's needed is to simply (?) convert the contour line to polygon.
I'm currently experimenting with this - the problem is to create closed polygons per tile, similar to the sea areas mkgmap can create from coastlines. This is what it looks like when it's working(when no open contours are involved): http://img30.imageshack.us/img30/9595/img0854oj.jpg It works quite fast, even if there are many dithering layers on top of each other. Maybe parts of the sea polygons code could be reused to extend contour areas to the tile borders. -Martin

nice! How were you able to close contours along tile borders? Is it possible to pre-process the contour tiles before mkgmap? On 9/26/09, Martin Simon <grenzdebil@gmail.com> wrote:
2009/9/26 maning sambale <emmanuel.sambale@gmail.com>:
Very nice. Has anyone tried this with mkgmap?
http://www.cgpsmapper.com/download/Creating%20custom%20types%20to%20represen...
What's needed is to simply (?) convert the contour line to polygon.
I'm currently experimenting with this - the problem is to create closed polygons per tile, similar to the sea areas mkgmap can create from coastlines.
This is what it looks like when it's working(when no open contours are involved):
http://img30.imageshack.us/img30/9595/img0854oj.jpg
It works quite fast, even if there are many dithering layers on top of each other.
Maybe parts of the sea polygons code could be reused to extend contour areas to the tile borders.
-Martin _______________________________________________ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
-- cheers, maning ------------------------------------------------------ "Freedom is still the most radical idea of all" -N.Branden wiki: http://esambale.wikispaces.com/ blog: http://epsg4253.wordpress.com/ ------------------------------------------------------

On Sat, Oct 03, 2009 at 09:01:33PM +0800, maning sambale wrote:
nice! How were you able to close contours along tile borders? Is it possible to pre-process the contour tiles before mkgmap?
Another idea: would it be possible to create a global contour line map from the ASTER data and distribute it? Could the contour line map be an overlay on a more variable map? Would the tile borders have to match? Could the two maps (contours and OSM-based overlay) be enabled or disabled from the device's settings menu? It would be useful to have a "static" contour line map, because elevation data does not change (or is not surveyed) as often as OpenStreetMap. Apparently, the ASTER data is not that proprietary, after all. There is a Norwegian mountain cycling map at http://mtbmap.org/ that acknowledges ASTER. According to a forum post, these are the rules:
ASTER GDEM Policy Agreements
* I agree to redistribute the ASTER GDEM only to individuals within my organization or project of intended use or in response to disasters in support of the GEO Disaster Theme. (Required) * When presenting or publishing ASTER GDEM data, I agree to include "ASTER GDEM is a product of METI and NASA."
If the ASTER data is a set of GeoTIFF files (raster files, high resolution), my understanding is that the contour lines (vector lines, lower resolution) would not be "redistributing" the data but "presenting or publishing" it. Apparently, that is how the Norwegians are interpreting it. Best regards, Marko
On 9/26/09, Martin Simon <grenzdebil@gmail.com> wrote:
2009/9/26 maning sambale <emmanuel.sambale@gmail.com>:
Very nice. Has anyone tried this with mkgmap?
http://www.cgpsmapper.com/download/Creating%20custom%20types%20to%20represen...
What's needed is to simply (?) convert the contour line to polygon.
I'm currently experimenting with this - the problem is to create closed polygons per tile, similar to the sea areas mkgmap can create from coastlines.
This is what it looks like when it's working(when no open contours are involved):
http://img30.imageshack.us/img30/9595/img0854oj.jpg
It works quite fast, even if there are many dithering layers on top of each other.
Maybe parts of the sea polygons code could be reused to extend contour areas to the tile borders.
-Martin _______________________________________________ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
-- cheers, maning ------------------------------------------------------ "Freedom is still the most radical idea of all" -N.Branden wiki: http://esambale.wikispaces.com/ blog: http://epsg4253.wordpress.com/ ------------------------------------------------------ _______________________________________________ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev

2009/10/3 Marko Mäkelä <marko.makela@iki.fi>:
Another idea: would it be possible to create a global contour line map from the ASTER data and distribute it? Could the contour line map be an overlay on a more variable map? Would the tile borders have to match? Could the two maps (contours and OSM-based overlay) be enabled or disabled from the device's settings menu?
Yes, I already do this with my garmin map. It has elevation data, "base" map and maxspeed layer to be switched on and off individually. Have a look at these commands that explain how the German "All in one Map"(not my work!) is created: http://wiki.openstreetmap.org/wiki/DE:All_in_one_Garmin_Map#Technik You only need gmaptool and the right family and product ids in your "layers". :-) But I use SRMT, as I don't know how to use ASTER data. -Martin

Marko Mäkelä wrote:
Another idea: would it be possible to create a global contour line map from the ASTER data and distribute it?
I don't know about ASTER, but with srtm2osm I didn't manage to generate the whole of Europe at once. Germany did work, though.
Could the contour line map be an overlay on a more variable map?
Yes, that's what I have done for my topo map: http://www.kleineisel.de/ralf/gps/garmin/
Would the tile borders have to match?
No, that's not necessary.
Could the two maps (contours and OSM-based overlay) be enabled or disabled from the device's settings menu?
Yes. If you use two different family-IDs, make two complete gmapsupp.img and join them with gmaptool it works.
It would be useful to have a "static" contour line map, because elevation data does not change (or is not surveyed) as often as OpenStreetMap.
Sure, I recycle my SRTM layers when I make an updated OSM layer. I did recreate them a few weeks ago because the "max 4 tiles bug" in mkgmap splitter was fixed.

2009/10/3 maning sambale <emmanuel.sambale@gmail.com>:
nice! How were you able to close contours along tile borders? Is it possible to pre-process the contour tiles before mkgmap?
I'm currently not able to close them - the screenshot is from an area in the middle of a tile where only closed contours are visible. I think a pre-processing program would have to find nodes at the tile border, pick one of them and 1. find the way it belongs to 2. find the way of the next border node in clockwise direction and find out if it is tagged with a higher value of "ele" than the current way. 3.a If so, look in clockwise diretion for a node of ways with the same elevation and add it's way to the current way OR if there is none, add a point at the next tile corner to the current way. 3.b Else, do the same in counter-clockwise direction. 4. if the other end of the current way is reached, close it and delete it from the list of ways and nodes to be considered. At least that's how I (non-programmer, the highest I've reached are simple, dumb shell scripts) imagine it could work... There also is a problem with contours that are *lower* than the surroundings and *not* cut - they need to be the "inner" member of a multipolygon relation with the next higher contour as "outer", as else they will be covered by it. If you would like to help with this, I can send you my stuff. -Martin

Martin Simon schrieb:
2009/10/3 maning sambale <emmanuel.sambale@gmail.com>:
nice! How were you able to close contours along tile borders? Is it possible to pre-process the contour tiles before mkgmap?
I'm currently not able to close them - the screenshot is from an area in the middle of a tile where only closed contours are visible.
Are you creating the contour lines with mkgmap? Actually, it wouldn't be hard to extend the current algorithm to close the contour lines along the edge of map - I will have a look at it. Best wishes Christian

2009/10/4 Christian Gawron <christian.gawron@googlemail.com>:
Martin Simon schrieb:
2009/10/3 maning sambale <emmanuel.sambale@gmail.com>:
nice! How were you able to close contours along tile borders? Is it possible to pre-process the contour tiles before mkgmap?
I'm currently not able to close them - the screenshot is from an area in the middle of a tile where only closed contours are visible.
Are you creating the contour lines with mkgmap? Actually, it wouldn't be hard to extend the current algorithm to close the contour lines along the edge of map - I will have a look at it.
No, I use Srtm2Osm.exe to generate contour tiles of 1x1 degree, I don't know how to use the DEM feature of mkgmap that was discussed here a few weeks ago as there seems to be some external lib involved... -Martin
participants (5)
-
Christian Gawron
-
maning sambale
-
Marko Mäkelä
-
Martin Simon
-
Ralf Kleineisel