[gdal-dev] MapInfo mixed geometry

Sebastian E. Ovide sebastian.ovide at gmail.com
Wed Sep 1 12:28:35 EDT 2010


Thanks !

On Wed, Sep 1, 2010 at 1:54 PM, Frank Warmerdam <warmerdam at pobox.com> wrote:

> Sebastian E. Ovide wrote:
>
>> Hi All,
>>
>> I have MapInfo mixed geometry files. As MapServer doesn't support layers
>> wityh mixed geometry, Is it possible to use gdal for extracting its points,
>> its polygaons etc... and save them in different files ?
>>
>
> Sebastian,
>
> You can do something like:
>
> ogr2ogr your_points.shp mixed.tab -where "ogr_geometry='point'"
>
> ogr2ogr your_lines.shp  mixed.tab -where "ogr_geometry='linestring'"
>
> ogr2ogr your_lines.shp  mixed.tab \
>   -where "ogr_geometry='polygon' or ogr_geometry='multipolygon'"
>
> Note that MapServer can draw from a mixed file, but you would need
> to define a layer for each type of geometry you want to draw and
> there are inefficiencies since the other geometries are discarded
> after some expense reading for the layers they don't apply to.  So
> splitting things, as above, is best for large files.
>
> Best regards,
> --
>
> ---------------------------------------+--------------------------------------
> I set the clouds in motion - turn up   | Frank Warmerdam,
> warmerdam at pobox.com
> light and sound - activate the windows | http://pobox.com/~warmerdam<http://pobox.com/%7Ewarmerdam>
> and watch the world go round - Rush    | Geospatial Programmer for Rent
>
>


-- 
Sebastian E. Ovide
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/gdal-dev/attachments/20100901/834d73e7/attachment.html


More information about the gdal-dev mailing list