Hi,

I have question regarding proper use of Polygonizer class (I'm using NTS, but 
it shouldn't matter I hope)

I'm working on utility to create convex hull of a point set.

Result of first step of that utility is whole bunch of line strings 
representing convex hull or point set.

Then I'm using Polygonizer to transform list of line strings to polygon.

Problem is that sometime result of polygonizer is not one 'Big' outlining 
polygon (having potentially some holes in it), but instead lot of small 
polygons.

I suspect that problem is when some line segments lie on the boundary and as 
well form smaller hole in polygon that somehow create probelm.

It's a bit difficult to describe, but I'll try to simplify it as much as 
possible.

Imagine chess board (8x8 square) having line segments of lenght 1 all arround. 
If it happens that there are line segments arroung some of little squares 
arround the edges (e.g. field C1) then instead or returning big polygon (8x8) 
polygonizer return only small one (1x1 C1 square).

My guess is that line segment on the edge get assigned to that small polygon, 
and then rest of the line segments do not form closed ring.

That is of course totaly different of what I need, as I want to get back 
largest possible polygon, potentially discarding all those smaller but it seem 
that they take precedence and mess up desired output.

Is there any way to control how polygonizer work so that i get my big polygon 
back.


Thanks
Dragan Blagojevic


-- 
View this message in context: 
http://n2.nabble.com/polygonizer-and-line-strings-tp2572524p2572524.html
Sent from the jts-devel mailing list archive at Nabble.com.

_______________________________________________
jts-devel mailing list
jts-devel@lists.jump-project.org
http://lists.refractions.net/mailman/listinfo/jts-devel

Reply via email to