[geos-devel] Clip and Union --> is my implementation correct?

Paul Meems bontepaarden at gmail.com
Tue Oct 15 01:05:36 PDT 2019


 Hi List,

I have a large shapefile (land use) with a lot of small shapes (392k).
I also have a smaller shapefile (catchments) with larger shapes (2.5k).
The smaller shapefile overlaps the larger shapefile in the center.

I need to create a new shapefile (expected number of shapes is several
100k) that have the values of the land use and the catchments combined.
Currently, I'm doing a GEOSClip() of the land use by the catchment first
and then a GEOSUnion of the clipped result and the catchment.

This is a bit slow. The clipping already takes 40 minutes.

Am I using the right approach or should I use a different one?

Extra info. I'm using MapWinGIS (C++) which includes GDAL and GEOS.
This is the implementation of GEOSClip:
https://github.com/MapWindow/MapWinGIS/blob/develop/src/COM%20classes/Shapefile_Geoprocessing.cpp#L1936
It was created years ago. Perhaps the implementation can/should be
optimized as well.

Thanks,

Paul Meems
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/geos-devel/attachments/20191015/998158ab/attachment.html>


More information about the geos-devel mailing list