[gdal-dev] Problem with writing Python interface using swig
I have a C++ project where I used GDAL OGR geometry as the basic data type. When I try to write a python interface for my project using Swig but I encountered a problem that the length and number of points returned from OGRLinestring become some strange values.
I reproduce the error below.
The c++ code as a file `mygdal.hpp`
#include "gdal/ogrsf_frmts.h" // C++ API for GDAL
OGRLineString* cutoffline = new OGRLineString();
std::cout<<"Number of points "<< cutoffline->getNumPoints()<<"\n";