[QGIS-Developer] closestSegmentWithContext() with epsilon in Python

Radim Blazek radim.blazek at gmail.com
Fri Nov 24 03:58:59 PST 2017


Hi,

I found that closestSegmentWithContext() in Python is useless for
geometries in geographic crs, because small squared distances are set
to zero because of epsilon threshold. See for example:
https://user-images.githubusercontent.com/29453443/32953189-c395d8a0-cbaf-11e7-8d71-b5869392f08b.PNG
points are not assigned to lines correctly because square distances are wrong.

Would it be possible to add epsilon as keyword argument to
closestSegmentWithContext() and possibly other methods taking epsilon
in C++?

I am not sip/python expert, no idea how to do that.

Thanks
Radim


More information about the QGIS-Developer mailing list