2.2.41. Convert lines to polygons

Each line turns into a polygon. Straight and self-intersected lines are omitted. Multilines are exploded to multiple features.

Input:

  • Linear vector layer in GeoJSON or GeoPackage format or ESRI Shapefile in a zip archive.

Output:

  • Polygon layer;

  • Linear layer with remaining self-intersecting lines.

Both files are in the same format as the input.

Launch the tool: https://toolbox.nextgis.com/t/lines2poly

Example:

../../_images/lines2poly_input_en.png

Pic. 2.28. Example input

../../_images/lines2poly_result_en.png

Pic. 2.29. Example output: polygons and sefl-intersecting lines

Try it out using our sample:

Download input dataset to test the instrument. Step-by-step instructions included.

Get the output to additionally check the results.