I'm using desify to increase the number of vertices in my line feature so I get evenly spaced vetices along each straight line segment.
However the densify is not giving me the control I want - it is putting in more points than I require.
Example:
Simple 2 point line - 1918m long
Densify - Distance method - Distance = 600m
Result: 6 point line with vertex distance = 384m.
Expected result: 5 point line with vertex distance = 479m
This is a very simple example but my feature contains hundreds of thousands of km of lines so I'm getting a lot more points than I want.
Why is densify making this decision? Is there a tool that offers more control?
Can you provide the coordinates of one geometry, before and after? It would be a lot easier to explain the behavior if we could see it.
- V
Sorry I can't post example data.
Here's some more info:
How does the Densify tool decide on the separation of vertices when a DISTANCE Densification Method is used? - it doesn't seem to offer the control I require.
Is this clearer?
I've written my fair share of custom densification code, and have struggled to find the "best" vertex distribution algorithm, especially when using Cartesian distances with geodetic coordinates. I've found many different options:
This last methodology would explain the occasional need to add an extra vertex over those that are strictly necessary, but it's impossible to tell without the actual data (or the source to the Densify tool).
- V
If the data are in projected coordinates try this toolbox I curious to see if it performs the same way as the others. Also, certainly you can select one polyline segment where densification went wrong and share it for testing purposes.
I assuming you're using the Densify tool. According to this thread, you're seeing the expected results.