Brandon,
If I understand your requirements, it sounds like you want to build a
linear network over a somewhat "fuzzy" dataset of route lines, by
conflating or snapping the routes linework together to form a "best fit"
network.
If so - then you're tackling a hard problem, and there's nothing directly
in JTS that will do this.
The RoadMatcher code (which is part of later JCS distributions) does do
something more like this, although it was still addressing a simpler
problem - namely, that of conflating one linear network to another one
which is assumed to be "correct".
As you've observed, the combination of the JTS GeometrySnapper and
SegmentStringDissolver is close, but as with many problems in computational
geometry this is a case of horseshoes and hand grenades - "close" does not
mean that it can be used to provide a solution.
I can think of a couple of different approaches to this problem. The most
thorough would probably be to "average" all the nodes in the input edges
first, then connect them to match the topology in the original edges. A
simpler approach would be to build a clean edge graph incrementally, by
snapping and merging each edge into the evolving graph. You'd need to
build your own graph structure to do this, although it could be adapted
from an existing data structure. There aren't that many ways to build a
linear graph, but the devil is in the details. In this case the graph
structure will need to support both geometric access (for the snapping) and
topological access. And it needs to be an dynamic (mutable) structure,
probably with an associated dynamic spatial index as well.
Hope this helps.
Martin Davis
------------------------------------------------------------------------------
Introducing AppDynamics Lite, a free troubleshooting tool for Java/.NET
Get 100% visibility into your production application - at no cost.
Code-level diagnostics for performance bottlenecks with <2% overhead
Download for free and get started troubleshooting in minutes.
http://p.sf.net/sfu/appdyn_d2d_ap1
_______________________________________________
GeoTools-GT2-Users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users