[postgis-devel] Postgis "Split" with tolerance

Rémi Cura remi.cura at gmail.com
Thu Nov 28 08:22:11 PST 2013


Hey everybody,

again tolerance issue ! what !  ;-)

In the liblwgeom.c file ,
I changed
"if ( dist > 0)   /* TODO: accept a tolerance ? */"

to

//@TOTEST @CHECK change by Remi-C : adding a small tolerance
vstol = ptarray_length_2d(lwline_in->points) / 1e12; //note : we don't
really need to compute length, we could just compute
//max (abs(max(x)-min(x)) , abs(max(y)-min(y)) ), it would be way faster
if ( dist > vstol )   /* TODO: accept a tolerance ? */


So know we can split a line by a point !
Any thought?

Cheers,
Rémi-C
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-devel/attachments/20131128/4f86e00d/attachment.html>


More information about the postgis-devel mailing list