[postgis-tickets] [PostGIS] #3719: Error: Invalid number of points in LinearRing
PostGIS
trac at osgeo.org
Wed Mar 21 08:14:31 PDT 2018
#3719: Error: Invalid number of points in LinearRing
-------------------------+-----------------------------
Reporter: tiiipponen | Owner: pramsey
Type: defect | Status: new
Priority: medium | Milestone: PostGIS Fund Me
Component: postgis | Version: 2.3.x
Resolution: | Keywords:
-------------------------+-----------------------------
Comment (by tiiipponen):
The minimum solution is to put minimum output segments to two. And why not
put it to five segments, as there was in code sample I send to you. Five
segments looks better arc-geometry than two.
This later discussion concerns accuracy and is strongly linked to this
update request.
32 segments per quadrant doesn't give accurate results from spatial
queries.
It is good that ST_CurveToLine has developed that way and user can give
his/her own tolerance as parameter.
But this ticket concerns on function ST_Intersects() and some other
similar functions, where PostGIS is doing linearization internally and
temporarily when sending geometry to GEOS library function, who doesn't
understand arc-geometries. Many of these functions returns geometries with
original arcs, so I can not linearize then beforehand with function
ST_CurveToLine.
So how to put proper tolerance for internal functions?
For example in Oracle it can be given in the geometry metadata definition
for a table or as an input parameter to certain functions.
PostGIS doesn't have either of these concepts. Now only in function
ST_CurveToLine.
So how to give that tolerance for these internal handlings? I am
interested to hear your ideas.
If somebody asks it from me, I have some proposals: \\
1. New tolerance attribute to view "public.geometry_columns". \\
2. Some other place to put this default tolerance parameter for example in
database level. \\
3. Tolerance parameter to all functions, who sends its geometries to GEOS.
\\
4. Default tolerance to 0.001 or at least 0.01 if efficiency is problem.
If it is not, then why not to put default tolerance to 0.0005 or even
0.0001. \\
5. Default tolerance to 10 000 segments per quadrant for all internal
linearizations.
--
Ticket URL: <https://trac.osgeo.org/postgis/ticket/3719#comment:15>
PostGIS <http://trac.osgeo.org/postgis/>
The PostGIS Trac is used for bug, enhancement & task tracking, a user and developer wiki, and a view into the subversion code repository of PostGIS project.
More information about the postgis-tickets
mailing list