Notgnoshi / generative

Generative art. A suite of composable tools to generate, transform and visualize WKT geometries
MIT License
25 stars 3 forks source link

Join connected SEGMENTs into LINESTRINGS #145

Open Notgnoshi opened 1 year ago

Notgnoshi commented 1 year ago

Input:

LINESTRING(0 0, 0 1)
LINESTRING(0 1, 0 2)

Output:

LINESTRING(0 0, 0 1, 0 2)

Use a heuristic to traverse graph, and emit traversals as LINESTRINGs. Maybe add to the traverse tool? Or to geom2graph --graph2geom

The problem with geom2graph is:

  1. It's C++
  2. It outputs two-point LINESTRINGs, even when they're adjacent (because it uses GEOS for this)

Related: https://github.com/Notgnoshi/generative/issues/130