From the error message, it looks like you would need to specify the z coordinate. tr.TransformPoint(pt[0], pt[1], 0)
But both old gen and new gen python bindings have z coordinate as an optional argument. I have tested that it works with current trunk. --> Looks like your OpenEV uses an unofficial/uncommon/old version of the new gen bindings. because the osr.py file provided with FWTools uses old gen bindings... Weird Le Wednesday 10 June 2009 23:19:12 Gong, Shawn (Contractor), vous avez écrit : > hi list, > > I've been getting the following error from osr.py: > File "C:\iapro\OpenEV\python\lib\site-packages\osgeo\osr.py", line 618, > in TransformPoint return > _osr.CoordinateTransformation_TransformPoint(*args) > NotImplementedError: Wrong number of arguments for overloaded function > 'CoordinateTransformation_TransformPoint'. Possible C/C++ prototypes are: > TransformPoint(double [3]) > TransformPoint(double [3], double, double, double) > > > The function I'm calling is below. I've tried it with different input > combinations, but I always get the same result. > > tr = osr.CoordinateTransformation(ref, proj) > tr_pts = [] > for pt in geo_nodes: > tr_pts.append(tr.TransformPoint(pt[0], pt[1])) > > > Has anyone seen the error, does it has something to do with Swig? > > > thanks, > Shawn > > > _______________________________________________ > gdal-dev mailing list > [email protected] > http://lists.osgeo.org/mailman/listinfo/gdal-dev _______________________________________________ gdal-dev mailing list [email protected] http://lists.osgeo.org/mailman/listinfo/gdal-dev
