Polygon Centerline¶
Summary¶
Center-line (ie. medial axis) of the input polygons based on an auxiliary stream network.
Tags:vector
, polygon
, medial axis
, disaggregation
, model
, centerline
, valley
Usage¶
Compute the medial axis of one or multiple polygon(s). Useful for computing centerlines of a valley bottom or any other polygon for which you have a corresponding stream network.
If a stream network is not available for your polygon (ex. historical channel), it is possible to use instead a created LineString which cut the polygon boundaries upstream and downstream. This LineString needs to be an approximation of the medial axis to guide the centerline computation.
The polygons and the stream network features are linked using a common attribute (like a FID).
Algorithm:
Intersect the input polygon boundaries with the stream network
Keep the most distant resulting points (upstream and downstream points)
Cut the input polygon boundaries with the upstream and downstream points (get two polygon sides)
Compute Voronoi polygons with points on the sides and dissolve it on each side
Cut the Voronoi lines with the input polygon
Remove duplicate lines
Smooth result
Advices:
You can apply a small buffer on your polygons to avoid network going out of the polygon too many times increasing drastically the computing time.
You can also extend the network lines to be sure they cut the polygons upstream and downstream.
Parameters¶
Parameter | Description | Type |
---|---|---|
Input polygon
POLYGON
|
Polygon to compute the centerline. | Polygon |
Stream network or up/downstream polyline (see doc)
NETWORK
|
Stream network to compute the upstream and downstream points. ex. french BDCarthage. | LineString |
Disaggregation distance
STEP
|
Distance between points on the input polygon sides to compute the
Voronoi polygons. The smaller the distance, the smoother the result will be.
Default value: 25
|
Number |
Smoothing factor
SMOOTH
|
Number of iterations to smooth the resulting centerline.
Default value: 5
|
Number |
Output centerline
CENTERLINE
|
Resulting centerline. | LineString |