Re: [Geotools-gt2-users] SimpleLine contains some points

2012-11-14 Thread Michael Bedward
Hi Steve, > Is the tolerance that you speak of referring only to Geometry.buffer()? I've > tried setting Geometry.buffer but it had no effect on my line string > comparison. Calling geomA.buffer(dist) does not modify geomA, it returns a new buffered geometry... double dist = ... Geometry geomB =

Re: [Geotools-gt2-users] SimpleLine contains some points

2012-11-14 Thread Steve Mitchell
Is the tolerance that you speak of referring only to Geometry.buffer()? I've tried setting Geometry.buffer but it had no effect on my line string comparison. geometryA.buffer(100); geometryA.contains(geometryB) --> false, except when geometryB is an exact subset of points from geometryA. geometry

Re: [Geotools-gt2-users] SimpleLine contains some points

2012-11-14 Thread Michael Bedward
Hello Steve, If you can define a tolerance within which geometries should be treated as coincident you could use Geometry.buffer and then test for intersection etc. Michael On 15 November 2012 03:07, Steve Mitchell wrote: > Trying to find the right way to test line overlap when the points are n

[Geotools-gt2-users] SimpleLine contains some points

2012-11-14 Thread Steve Mitchell
Trying to find the right way to test line overlap when the points are not common. I have a set of lines containing points collected from a GPS receiver. I need to find which of those lines travel a particular stretch of the route. The functions geometryA.contains(geometryB) and geometryB.within(geo