> > There are OGR_G_GetPointCount in ogr_api.h and GetPointCount method in the > Geometry class in Swig bindings. >
Right, I was also trying to figure out this, this is my test code: lineshp = driver.Open('/home/pcorti/data/shapefile/line.shp') linelyr = lineshp.GetLayer(0) feat = linelyr.GetNextFeature() geom = feat.GetGeometryRef() print geom.GetGeometryName() LINESTRING print geom.GetPointCount() 8 This is also suggested on the doc [0] best regards P [0] http://www.gdal.org/ogr/classOGRLineString.html#7ea70605cd6ac71221177586c2ec5cfc -- Paolo Corti Geospatial software developer web: http://www.paolocorti.net twitter: @paolo_corti _______________________________________________ gdal-dev mailing list gdal-dev@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/gdal-dev