Opened 15 years ago
Last modified 14 years ago
#231 closed enhancement
New distance-calculations proposal — at Version 3
Reported by: | nicklas | Owned by: | pramsey |
---|---|---|---|
Priority: | medium | Milestone: | PostGIS 1.5.0 |
Component: | postgis | Version: | |
Keywords: | Cc: |
Description (last modified by )
A hopefully more structured ticket than #137
The patch attached includes:
new functions:
- st_shortestline
- st_longestline
- st_dfullywithin
- st_max_distance
(this is really a fix to a long standing bug — st_max_distance has existed since at least 1.2 but has never worked - (older versions give Not yet implemented))
enhancements affecting st_distance, st_dwithin and the functions above:
- a better handling of "holes" in polygons.
- a sudden stop in iteration when the distance in st_dwithin is satisfied. Before it was checked for every subgeom.
- a new way of calculating distances between lines and polygons that don't intersect.
Probably the last one is the most important. On big geometries it makes a big difference.
Beside the patch I have attached a document where I try to explain the idea behind the distance-calculation.
/Nicklas
Change History (4)
by , 15 years ago
comment:1 by , 15 years ago
Nick,
Does this particular patch include the fix for ST_Max_Distance as well (i saw it in the patch you sent). I know you had it in a separate patch and I said to hold it separately since it was a fix to a long standing bug and not an enhancement. Though not sure how everyone feels about back-porting that particular fix to 1.4.1 since 1.4 and below has the function but gives annoying message "This function is unimplemented yet" so technically its not an API change — its a bug fix.
Thanks, Regina
comment:2 by , 15 years ago
Yes, you are right, it includes st_max_distance too. Maybe you can put it in the description. I don't think I can. /Nicklas
comment:3 by , 15 years ago
Description: | modified (diff) |
---|
explanation of the distance calculation