[gdal-dev] openFileGDB driver - polygons with bezier curves not exporting correctly

Even Rouault even.rouault at spatialys.com
Mon Dec 4 04:42:14 PST 2017


> I have been provided with a polygon layer in ESRI FileGDB format
> (created in ArcMap v10.3 at least, maybe 10.4 or 10.4.1). The polygons
> in the layer have been digitised using a mix of straight line segments
> and bezier curves / true arcs, which I've verified in ArcMap by
> looking at the geometry in edit mode.
> 

Lauren,

Bezier curves have no equivalent representation in Single Feature modelling, so they are 
linearized as small straight segments. Up to now, 100 intermediate points were used, which 
in a case like your dataset was indeed excessive. I've tweaked the logic in trunk to be smarter 
(taking into account the angular difference between the start and end tangents, and the 
relative length of those tangents vs the direct distance), and now the resulting GPKG from 
the conversion is 9 MB, with after a quick visual check is nearly rendered the same as the 
previous brute force version

https://trac.osgeo.org/gdal/changeset/40941

Regarding layer geometry types, given that there will be a mix of MultiPolygon and 
MultiSurface (MultiSurface due to the polygons with circular portion), and that this cannot be 
anticipated before reading the layer content, you may want to either add "-nlt 
MULTISURFACE" (that will keep the circular portion as such), or "-nlt MULTIPOLYGON") (to 
linearize everything). On your sample dataset, the difference of size is neglectable: 9064448 
for the output of -nlt MYLTISURFACE vs 9080832 for the output of -nlt MULTIPOLYGON.

Even

-- 
Spatialys - Geospatial professional services
http://www.spatialys.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/gdal-dev/attachments/20171204/c7c5e593/attachment.html>


More information about the gdal-dev mailing list