Opened 9 years ago

Closed 9 years ago

#5847 closed defect (invalid)

GetGeomType returns incorrect code for 3D Polygon

Reported by: dr Owned by: hobu
Priority: normal Milestone:
Component: PythonBindings Version: 1.11.1
Severity: normal Keywords:
Cc:

Description (last modified by dr)

When I try to get geometry type from Python:

>>> from osgeo import ogr
>>> driver = ogr.GetDriverByName('ESRI Shapefile')
>>> path = '3dpoly.shp'
>>> dataSource = driver.Open(path, 0)
>>> layer = dataSource.GetLayer()
>>> layer.GetGeomType()
-2147483645

But ogrinfo returns correct information:

INFO: Open of `3dpoly.shp'
      using driver `ESRI Shapefile' successful.
1: 3dpoly (3D Polygon)

Attachments (1)

3dpoly.zip (1.4 KB ) - added by dr 9 years ago.

Download all attachments as: .zip

Change History (3)

by dr, 9 years ago

Attachment: 3dpoly.zip added

comment:1 by dr, 9 years ago

Description: modified (diff)

comment:2 by Even Rouault, 9 years ago

Resolution: invalid
Status: newclosed

Not a but:

>>> from osgeo import ogr
>>> ogr.wkbPolygon25D
-2147483645
Note: See TracTickets for help on using tickets.