[gdal-dev] multipolygon to polygon
Mohammed Rashad
mohammedrashadkm at gmail.com
Thu Feb 24 08:43:32 EST 2011
How to convert mutipolygon to polygon
my code
string geometry = "MULTIPOLYGON (((76.742484035494002
9.949536084104899,76.783465713734998 9.8207365239198,76.818592866512006
9.8773302700617,76.842010968363994 9.931972507716001,76.742484035494002
9.949536084104899)))";
char *geom = (char *) geometry.c_str();
OGRGeometry *OLGeometry = NULL;
OGRGeometryFactory::createFromWkt( &geom, NULL, &OLGeometry );
the OLGeometry is multipolygon I need it as polygon as given below.
Note: both are not equal
POLYGON ((76.334618761574006 10.378867951388999,76.338521778548994
10.419849629630001,76.404873067129998 10.349595324074,76.371697422840001
10.271534984568,76.334618761574006 10.378867951388999))
--
Thanks && Regards
Rashad
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/gdal-dev/attachments/20110224/293dd2c8/attachment.html
More information about the gdal-dev
mailing list