Hi all,
attached is a patch that addresses the following problem:
When you use e.g. GPSMapEdit to look at the polygons produced by
mkgmap for resolutions < 24,
you may notice e.g. white triangles in the ocean where there should be
water.
I am not sure if they are visible in Basecamp or MapSource or a Garmin
device, but they are not intended and they sometimes "confuse" the
optimization filters.
They are produced when the Douglas-Peucker-Filter removes points
which are somehow important.
Important points are
1) Those that lie on the bounding box of the polygon
2) Points which connect a hole with the outline
Another problem was
The patch changes the code so that these points are preserved
before line simplification is applied. It also makes sure that
the result doesn't depend on the order in which the shapes
are processed.
You may see small changes in img size, sometimes size is decreased,
sometimes increased (more likely). If you see changes > 10 kB on a single img file
compared to r3683, please post a link to the corresponding input file.
If I hear no complains I'll commit this patch next Monday.
A binary for testing is here:
http://files.mkgmap.org.uk/download/303/mkgmap.jar
Gerd