I have a very large .gml file with multiple layers in it. I would like to export one of these layers to .shp. It is a polygon layer (of lakes). However, I am getting the error:
ERROR 1: Unrecognised geometry type
The ogr command I was using:
ogr2ogr -f "ESRI Shapefile" output.shp input.gml layername
Any thoughts? Is it possible the polygon layer is somehow incorrectly defined as a surface in the GML? Any way I can force it to be a polygon? Or is it something else entirely? I don't often work with .gml, so may be missing something obvious...
Here is a snip of (what appears to be) the relevant info from an example feature in the example file linked below:
<gml:Surface srsName="EPSG:4140" srsDimension="2">
<gml:posList>52.2023177 -77.596532 52.2024007 -77.5963559 52.2028141 -77.5962899 52.2028362 -77.5964181 52.2026119 -77.5967049 52.2024106 -77.5967968 52.2023273 -77.5966966 52.2023177 -77.596532
So, the file is identifying it as a 'surface' as well as a 'PolygonPatch'? Perhaps the question should be: what is a 'surface' in a .gml file?