[Qgis-developer] new dependency on GEOS C++ library

Sandro Santilli strk at keybit.net
Thu Oct 1 04:55:41 PDT 2015


On Thu, Oct 01, 2015 at 01:39:37PM +0200, Sandro Mani wrote:

> As resulted from the discussion in the geos ticket: the goal is
> having the operations run in reduced precision, not just merely snap
> to grid. The discussion revealed however that snap to grid is
> basically what ends up being done with the current implementation,
> due to a mis-understanding of mine of the geos internals. As
> suggested in the geos ticket, I'd like to fix this to work as
> initially intended, and keep geosextra in QGIS until a new release
> of GEOS comes out which implements needed changes in the C-API.

That's fine by me.
I'm wondering if the easiest way to do it would be something like this:

 GEOSGeometry* GEOSGeometry_setFactory( GEOSGeometryFactory* factory, int roundCoordinates );

But note that for such a call, the "factory" parameter would need
to be alive for the whole lifetime of the returned GEOSGeometry
_and_ for any further product from it (operation involving it as an input).

These GeometryFactory links are sticky, that's what makes it hard to
deal with them.

--strk;


More information about the Qgis-developer mailing list