Question about additional functionality related to lineToPolygon function
See original GitHub issueHi guys, Thank you for this awesome library!
I would like to ask you one question regarding converting line to polygon. I’m using lineToPolygon
function and it works like a charm. But I need more functionality.
For example, I have one complex line, something like this, which was converted to polygon via lineToPolygon
function:
There is a lot of lines and shapes within polygon, which are part of this polygon. And I need to reduce it to avoid drawing unnecessary lines and make a correct searching inside it.
So the question is: Does Turf have functionality to detect crossed lines within polygon, remove these lines and make polygon like on the next screenshot?
Thanks
Issue Analytics
- State:
- Created 3 years ago
- Comments:7 (3 by maintainers)
Top Results From Across the Web
Splitting a polygon by multiple linestrings leaflet and turf.js
This is done in two steps. First step is to 'fatten' dividing line to one side, cut polygon by it and take into...
Read more >Combine feature collection into polygon turfjs - Stack Overflow
Just use turfs http://turfjs.org/docs/#lineToPolygon which Converts (Multi)LineString(s) to Polygon(s).
Read more >simplepolygon - Cesium Documentation
Returns: Feature collection containing the simple, non-self-intersecting one-ring polygon features that the complex polygon is composed of. These simple ...
Read more >Advanced geospatial analysis - Turf.js
Takes two (Multi)Polygon(s) and returns a combined polygon. If the input polygons are not contiguous, this function returns a MultiPolygon feature. Arguments ...
Read more >(PDF) Extended Web Direction Service to Avoid Obstacle on ...
However, most web routing service platforms cannot add points or areas to ... A set of spatial analysis functions in Turf.js was used...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Brilliant solution @stebogit , so elegant!
@alexeyvax if I understand correctly what you want to do, I think you could do something like this, where I destructured the line into points and generated a concave polygon out of them: