Question

Intersect Attributes

  • 7 February 2015
  • 4 replies
  • 1 view

I want to identify the places where the same line have two different elevations , inserting the point When a elevation pass to another elevation on the same line .

 

 


4 replies

Userlevel 2
Badge +17
Hi,

 

 

If the line is 3D line (i.e. every vertex has elevation as its z-coordinate), this procedure could be a solution.

 

 

1. Create middle points between two adjacent vertices having different elevation.

 

(1) Decompose the line into individual line segments by the Chopper (Mode: By Vertex

 

Maximum Vertices: 2).

 

(2) Extract elevations (z-coordinate) of start and end nodes of each line segment.

 

CoordinateExtractor1 (Index: 0, Z Attribute: _z0)

 

CoordinateExtractor2 (Index: 1, Z Attribute: _z1)

 

(3) Select line segments whose "_z0" is not equal to "_z1" with the Tester.

 

(4) Transform the selected line segments into their middle points with the CenterPointReplacer. The points represent locations in which elevation is changing on the original line.

 

 

2. Overlay the middle points and the original line.

 

Add a PointOnLineOverlayes; send the resulting points to the Point port; send the original line to the Line port.

 

The line will be split at the points. You can then re-connect the split lines using the LineJoiner.

 

The resulting line will be the required line, to which the elevation changing points have been inserted.

 

 

Takashi
Userlevel 2
Badge +17
Are there perhaps three lines? blue - black - blue.

 

And do you need to create points at boundaries between two lines having different elevation as their attribute?

 

If so, need another approach.

 

Assuming that every input line has an attribute storing its elevation value (e.g. called "_elevation"), this could be a workaround.

 

Badge +3
Extract vertices, chopper maxvert=1

 

PointOnLineOVerlayer (or topologybuilder)

 

Make a list (grouped by line ID) of the points grouped by X AND Y coordinates. Count listelements. Check duplicate z value's (using duplicateremover or histogrammer)
Thank you for your answers!

 

It worked!!

Reply