Advertisement
Guest User

Untitled

a guest
Jun 16th, 2019
89
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.27 KB | None | 0 0
  1. # Select the source - in this case the selected layer
  2. layer = iface.activeLayer()
  3.  
  4. # Iterating through the features
  5. for f in layer.getFeatures():
  6.  
  7. # Get the geometry and interpolate the position at a distance (500)
  8. xy = f.geometry().interpolate(500)
  9. print(xy)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement