Skip to main content

I don't know if this can be done consistently. But if anyone would know how it would be you.

 

I would like to connect lines A and B and remove the "appendix" from line C.

 

An AnchoredSnapper was my first thought, but there are probably plenty of occurrences where B would connect to C instead of A. Is there a way to only snap to something that is in the "forward" perimeter? If I could get the below working it might be a better idea to extend the lines and then cut away the surplus.

Removing the appedix could be done with a LineOnLineOverlayer, but how do I find out which one is the shortest of the resulting lines?

 

How would you solve this? What is the "cleverest" solution?

 

Hi @aron,

These steps may help you-

  • Use LineOnLineOverlayer to split all intersection
  • Try SpatialRelator to find out dead end links like extra from C
  • Remove unnecessary dead end links based on length, lets take it as <30 meter (change this value as per your data) links.
  • Then try snapping

Snapper (end points only - short distances)

 

TopologyBuilder

on the nodes check the list to find those with only one edge (listElementCounter). (aka dangle nodes)

FeatureMerger/FeatureJoiner the dangle nodes to the edges - those with a match are dangle lines.

 

Calculate the length and either drop short lengths or use something like the LineToIntersectionExtender (https://knowledge.safe.com/questions/83658/fme-challenge-12-days-of-fme-hackathon-2018.html ) to connect them.

 

 


Thanks! I ended up using the topologybuider. That transformer sure had a learning curve though...


Thanks! I ended up using the topologybuider. That transformer sure had a learning curve though...

Yes it's been through several iterations, and while the latest version is an improvement in performance, it comes at the cost of intuitive use, particularly in the List Accumulation.

I'm also slightly irked by the fact that 2 ?3? versions ago they changed the port names from arcs to edges, but the edge list (when generated) still uses fme_arc_id and fme_arc_angle on the nodes, whereas the faces had the name change to _edge_id.


Reply