[mkgmap-dev] How to handle missing hgt files or files with voids?

2018-01-14 Thread Gerd Petermann
Hi all, 1) The current code (only) writes a log message with severity WARNING for a missing hgt file: "file xxx.hgt not found. Is expected to cover sea." I wonder if we can create a list of files that can exist or maybe a polygon that can be tested so that tiles which are knwon to cover land are

Re: [mkgmap-dev] HGT - getElevation()

2018-01-14 Thread Gerd Petermann
Hi Andrzej, I think your patch increases the box too much. I think we only need an aligned upper left corner. See my attached version. Still, even with my patch DEM size can increase quite a lot. I've created a map of bolivia with without --dem-dists option. Size of gmap folder: 223.511k with r4

Re: [mkgmap-dev] v4058 dem-tdb crashes

2018-01-14 Thread Gerd Petermann
Hi Andrzej, thanks, fixed with r4061: http://www.mkgmap.org.uk/websvn/revision.php?repname=mkgmap&rev=4061 Gerd Von: mkgmap-dev im Auftrag von Andrzej Popowski Gesendet: Montag, 15. Januar 2018 00:28:45 An: mkgmap-dev@lists.mkgmap.org.uk Betreff: Re: [

Re: [mkgmap-dev] v4058 dem-tdb crashes

2018-01-14 Thread Andrzej Popowski
Hi, addition: mkgmap compiles this example, if I remove --dem-dists. -- Best regards, Andrzej ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev

[mkgmap-dev] v4058 dem-tdb crashes

2018-01-14 Thread Andrzej Popowski
Hi Gerd, I have uploaded example at http://files.mkgmap.org.uk/download/392/test-crash.7z. java.lang.IndexOutOfBoundsException at java.nio.Buffer.checkIndex(Unknown Source) at java.nio.DirectByteBuffer.getShort(Unknown Source) at uk.me.parabola.mkgmap.reader.hgt.HGTRead

Re: [mkgmap-dev] r4046: new algo for background (0x4b) in overview map

2018-01-14 Thread Carlos Dávila
Canary Islands contains a single tile, that's why I saw no effect:-[ Spain map now has non-rectangular overview covering only map tiles. No mouse hover, as reported by Henning. El 14/01/18 a las 19:12, Gerd Petermann escribió: Hi Carlos, if your map contains multiple tiles that form a rectang

Re: [mkgmap-dev] r4046: new algo for background (0x4b) in overview map

2018-01-14 Thread Gerd Petermann
Hi Carlos, if your map contains multiple tiles that form a rectangular shape than the 0x4b polygons are combined again into one rectangle by ShapeMerger. Your map of spain looked different (empty area in part of portugal), so in that map you should see a different 0x4b polygon. Gerd _

Re: [mkgmap-dev] r4046: new algo for background (0x4b) in overview map

2018-01-14 Thread Carlos Dávila
MapEdit shows a rectangular map coverage area polygon from r4056, see attached screenshot. May be I'm doing something wrong. El 14/01/18 a las 18:23, Gerd Petermann escribió: Hi all, thanks for testing. Size changes can be caused by block-size change, but also a non-rectangular shape requires

Re: [mkgmap-dev] r4046: new algo for background (0x4b) in overview map

2018-01-14 Thread Gerd Petermann
Hi all, thanks for testing. Size changes can be caused by block-size change, but also a non-rectangular shape requires a few more bytes. You can use GpsMapEdit to check this. I'll continue experimenting with non-rectangular 0x4a an d0x4b shapes during the next days. Gerd ___

Re: [mkgmap-dev] r4046: new algo for background (0x4b) in overview map

2018-01-14 Thread Carlos Dávila
I have tested single layer map and also OSM layer+contour (transparent) layer, and I don't see any difference in MapSource. Contour lines are cut with the same poly than OSM data. Only difference is that overview img is slightly larger with r4056 vs r4051 in my test map (Canary Islands), but I

Re: [mkgmap-dev] HGT - getElevation()

2018-01-14 Thread Andrzej Popowski
Hi Gerd, > you just want to achive that the calculated postions are as close as > possible to the positions in the hgt file Yes. Linear interpolation is averaging too. If DEM can use exact values form HGT, then there will be no averaging. Even interpolated values near HGT node should be the sa

Re: [mkgmap-dev] HGT - getElevation()

2018-01-14 Thread Gerd Petermann
Hi Andrzej, If I got that right you just want to achive that the calculated postions are as close as possible to the positions in the hgt file. If you request a point that is not within the original area I would expect trouble (either NPE or wrong height 0). If that can happen, you should create

Re: [mkgmap-dev] HGT - getElevation()

2018-01-14 Thread Andrzej Popowski
Hi Gerd, > why you don't use the modified area for the hgtConverter as well? I need HGT resolution first. I guess resolution comes after initialization of hgtConverter. Probably area for hgtConverter should be expanded, or maybe initialized with a bit bigger area? -- Best regards, Andrzej __

Re: [mkgmap-dev] HGT - getElevation()

2018-01-14 Thread Gerd Petermann
Hi Andrzej, did not try the patch but I wonder why you don't use the modified area for the hgtConverter as well? Gerd Von: mkgmap-dev im Auftrag von Andrzej Popowski Gesendet: Sonntag, 14. Januar 2018 14:29:57 An: mkgmap-dev@lists.mkgmap.org.uk Betreff

Re: [mkgmap-dev] HGT - getElevation()

2018-01-14 Thread Andrzej Popowski
Hi Gerd, I have attempted to reduce interpolation, when DEM pixel size is the same as HGT pixel. I have stretched a bit area of DEM, so edges are aligned with HGT. I'm attaching a patch. Resulting map looks similar, only shading has moved a bit. I'm not sure if this is the result of differen

Re: [mkgmap-dev] r4046: new algo for background (0x4b) in overview map

2018-01-14 Thread Gerd Petermann
Hi Henning, I would expect differences when you combine a normal map with transparent tiles containing contour lines and those tiles overlap the normal tiles. Gerd Von: mkgmap-dev im Auftrag von Henning Scholland Gesendet: Sonntag, 14. Januar 2018 12:

Re: [mkgmap-dev] r4046: new algo for background (0x4b) in overview map

2018-01-14 Thread Henning Scholland
With using --transparent I can't see any differences compared to older mkgmap versions. Henning ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev

Re: [mkgmap-dev] r4046: new algo for background (0x4b) in overview map

2018-01-14 Thread Henning Scholland
Hi Gerd, seems to work for me, but I also don't know what I should expect to see. In BaseCamp/MapSource the map is still in rectangle shape with light yellow coloured back ground in the area without data. Only difference is, that there is no more mouse over, indicating the mouse is in 'Unbekanntem

Re: [mkgmap-dev] what do the 0x4a polygon in the mean?

2018-01-14 Thread Gerd Petermann
Hi Andrzej, ah, okay, so I looked at the DEM data created by GMapTool. I already wondered where this came from ;-) So forget those findings for Winter Activity Map. Still, Adria map seems to use the same trick, just not so strange values. Gerd Von: mkgmap

Re: [mkgmap-dev] what do the 0x4a polygon in the mean?

2018-01-14 Thread Andrzej Popowski
Hi Gerd, do you have overview for Winter Activity Map? I have never seen Winter map for PC, only gmapsupp.img. Maybe it is an overview created by GMapTool, check copyright in TRE. I have included procedure for creating empty DEM in GMapTool, which is using different distances. Actually it u

Re: [mkgmap-dev] what do the 0x4a polygon in the mean?

2018-01-14 Thread Gerd Petermann
Hi Andrzej, thanks for the hints. It seems indeed to be an alternative to use a very large overview-dem-dist value in combination with no DEM data. Garmin uses this in the "Winterkarte" and in the Adria Map. Also, the overview map of "Winterkarte" is the first map that I found in which dem-dist