logo separator

[mkgmap-dev] [PATCH] looped way patch for nod branch

From Mark Burton markb at ordern.com on Sat Feb 14 12:40:19 GMT 2009

Hi Bernhard,

> Hi,
> 
> it looks like the looped way check doesn't find all self intersection 
> ways. It just checks if some waypoint is the same like the last way 
> point. It misses loops somewhere in the middle of the way. This results 
> in route calculation hangups on the nuvi.
> 
> Here comes a patch for the nod branch that fixes the problem. The new 
> function should also work with multiple loops in a way. The check for 
> the two point loops needs a closer look. For now we only check if there 
> are more then 2 points in the way. I have tried a alternate way by 
> checking the distance between the intersection points to be greater the 
> 1 (j-pIdx>1). This will produce some more loop warnings. In one case I 
> was not able to see the reason for the warning so I commented the 
> alternate check out for now.
> 
> Berni.

Many thanks for the patch - I did wonder when I wrote the original code
whether there would be a problem with intersections.

I have reworked the patch to suit my way of thinking and I believe it
does a very similar job to the orginal but, to me, it's easier to
understand how it works. Also, this new code actually zaps consecutive
identical points.

Please try the attached patch (on nod branch, not on top of your patch)
and see what you think.

Cheers,

Mark

PS - I have received the POI patch for nod and will be trying it out at the
first opportunity.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: mb-loopedway.patch
Type: text/x-patch
Size: 2957 bytes
Desc: not available
Url : http://lists.mkgmap.org.uk/pipermail/mkgmap-dev/attachments/20090214/de4de894/attachment.bin 


More information about the mkgmap-dev mailing list