logo separator

[mkgmap-dev] shapes with holes

From GerdP gpetermann_muenchen at hotmail.com on Mon Jan 21 07:40:08 GMT 2013

Hi WanMil,

WanMil wrote
>> So you have to add some costly checks which point is directly
>> connectable. There is an algorithm (I don't remember the name) that
>> calculates which points are directly visible from a given point. If you
>> want to implement it would work. Just search Wikipedia and the polygon
>> algorithms. You will find it. I guss it's not very nice to the
>> performance...
> 
> Performing a quick search I haven't found an algorithm but the problem 
> is very similar to the visibility problems described in wikipedia:
> http://en.wikipedia.org/wiki/Visibility_%28geometry%29
> http://en.wikipedia.org/wiki/Isovist
> http://en.wikipedia.org/wiki/Visibility_graph
> http://en.wikipedia.org/wiki/Art_gallery_problem

thanks for  the input. So, it seems I have to find an algo that
finds the closest line. I have no idea reg. performance yet, but
I think I can use Line2D.ptSegDistSq() which calculates the
squared distance between the a point and a line seqment.

I'll try to implement that in the PolygonSplitterBase.split() method
because it is clearly an error that this method cuts areas without holes
into areas that have holes.

ciao,
Gerd




--
View this message in context: http://gis.19327.n5.nabble.com/shapes-with-holes-tp5745424p5745593.html
Sent from the Mkgmap Development mailing list archive at Nabble.com.


More information about the mkgmap-dev mailing list