[gdal-dev] export to geometrycollection.

Ahmet Temiz ahmettemiz88 at gmail.com
Thu Jun 17 00:06:51 PDT 2021


Thanks, I'll check it out.

On Sun, Jun 13, 2021 at 9:53 PM Even Rouault <even.rouault at spatialys.com>
wrote:

> Ahmet,
>
> use the OGRGeometryFactory::forceTo(geom, wkbGeometrycollection) method:
>
>
> https://gdal.org/api/ogrgeometry_cpp.html#classOGRGeometryFactory_1a26120382ccfec8ac4b5f932dd3a67c5f
>
> Even
> Le 13/06/2021 à 20:45, Ahmet Temiz a écrit :
>
> Hi,
> I exported the geometry to geojson as:
>
> OGRMultiPolygon * poOGRMultiPolygon= (OGRMultiPolygon * ) unionCascaded;
>     //
>  char * pszJSon= poOGRMultiPolygon->exportToJson();
>
> this generates:
>  "type": "MultiPolygon", "coordinates": ....
>
> But.  I need geometrycollection.
> How can I do that?
>
> regards
>
> --
> Ahmet Temiz
> Jeoloji Müh.
> Afet ve Acil Durum Yönetimi Başkanlığı
> Deprem  Dairesi Başkanlığı
>
>
> ________________________
>
> Ahmet Temiz
> Geological Eng.
>
> Disaster and Emergency Management
> of Presidency
>
> _______________________________________________
> gdal-dev mailing listgdal-dev at lists.osgeo.orghttps://lists.osgeo.org/mailman/listinfo/gdal-dev
>
> -- http://www.spatialys.com
> My software is free, but my time generally not.
>
>

-- 
Ahmet Temiz
Jeoloji Müh.
Afet ve Acil Durum Yönetimi Başkanlığı
Deprem  Dairesi Başkanlığı


________________________

Ahmet Temiz
Geological Eng.

Disaster and Emergency Management
of Presidency
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/gdal-dev/attachments/20210617/8b9f71c2/attachment.html>


More information about the gdal-dev mailing list