[geos-devel] [GEOS] #713: [Patch] Add GeometryPrecisionReducer to C API

GEOS geos-trac at osgeo.org
Thu Oct 1 04:01:15 PDT 2015


#713: [Patch] Add GeometryPrecisionReducer to C API
------------------------+---------------------------
 Reporter:  smani       |       Owner:  geos-devel@…
     Type:  defect      |      Status:  new
 Priority:  major       |   Milestone:  3.4.3
Component:  Default     |     Version:  3.4.2
 Severity:  Unassigned  |  Resolution:
 Keywords:              |
------------------------+---------------------------

Comment (by smani):

 Ok, bad news:

 https://github.com/manisandro/QGIS/commit/1738337ddea6d3242abd22bd8fc3b9d6b2ce3b2b
 {{{
     ********* Start testing of TestQgsGeos *********
     Config: Using QTest library 4.8.7, Qt 4.8.7
     PASS   : TestQgsGeos::initTestCase()
     FAIL!  : TestQgsGeos::lineIntersection(fixed) Compared values are not
 the same
        Actual (QString(resultwkt)): POINT (1.0000000000000000
 0.0000000000000000)
        Expected (wkt_result): POINT (2.0000000000000000
 0.0000000000000000)
        Loc: [/home/sandro/Documents/Devel/QGIS/qgis-
 master-2/tests/src/core/testqgsgeos.cpp(94)]
     PASS   : TestQgsGeos::cleanupTestCase()
     Totals: 2 passed, 1 failed, 0 skipped
     ********* Finished testing of TestQgsGeos *********
 }}}

 So intersection is running in full precision mode.

 From http://lists.osgeo.org/pipermail/geos-devel/2015-January/007086.html
 I had interpreted that GEOSGeometryPrecisionReducer_reduce would change
 the geometry factory of the reduced geometry. Did I get that wrong, or is
 more needed to have the operations run in reduced precision mode? Because
 that is what I'm ultimately interested in, the simple snap-to-grid is a
 start but not the full solution (and that could indeed be implemented
 stand-alone, without pulling in the GEOS C++ API as you pointed out on the
 mailing list).

--
Ticket URL: <https://trac.osgeo.org/geos/ticket/713#comment:14>
GEOS <http://trac.osgeo.org/geos>
GEOS (Geometry Engine - Open Source) is a C++ port of the Java Topology Suite (JTS).


More information about the geos-devel mailing list