Feature request #11515
Use ogr2ogr to create midpoints along lines
Status: | Closed | ||
---|---|---|---|
Priority: | Normal | ||
Assignee: | Giovanni Manghi | ||
Category: | Processing/GDAL | ||
Pull Request or Patch supplied: | No | Resolution: | fixed/implemented |
Easy fix?: | No | Copied to github as #: | 19785 |
Description
Following this blog post by Darren Cope, I found it is possible use ogr2ogr to create midpoints along a line using ogr2ogr. For example:
ogr2ogr OutputPoints.shp InputLines.shp -dialect sqlite -sql “SELECT AsText(Line_Interpolate_Point(InputLines.geometry, 0.5)),OTHER,FIELDS,CAN,GO,HERE from InputLines”
http://darrencope.com/2014/01/27/create-midpoints-along-lines-with-ogr/
It would be a valuable addition to Processing, since there's not equivalent algorithm available
History
#1 Updated by Giovanni Manghi about 10 years ago
- Assignee changed from Victor Olaya to Giovanni Manghi
#2 Updated by Andreas Neumann about 10 years ago
Do you actually want new point geometries or is it just necessary for symbology? In the latter case, there is the marker line in QGIS, by which you can position a marker on the mid-point of a line (term is "central point").
#3 Updated by Filipe Dias about 10 years ago
In this case, the actual geometries. In ecological surveys, it is quite common to plan surveys along line transects and to collect data in the middle, first or last quarter of the transect. This tool would be useful for that.
#4 Updated by Giovanni Manghi over 9 years ago
- Resolution set to fixed/implemented
- Status changed from Open to Closed
already implemented.