OGR: Unterschied zwischen den Versionen
Aus Geoinformation HSR
Stefan (Diskussion | Beiträge) (→Beispiele) |
Stefan (Diskussion | Beiträge) |
||
Zeile 10: | Zeile 10: | ||
* OGR wird als Teil der [http://fwtools.maptools.org/ FWTools] verteilt (Linux und Windows-Version]) | * OGR wird als Teil der [http://fwtools.maptools.org/ FWTools] verteilt (Linux und Windows-Version]) | ||
− | == ogr2ogr == | + | == ogr2ogr und ogrinfo == |
− | Dokumentation: | + | ogr2ogr-Dokumentation: |
* http://www.gdal.org/ogr/ogr2ogr.html | * http://www.gdal.org/ogr/ogr2ogr.html | ||
− | * http://www.gdal.org/ogr/ > OGR Supported Formats | + | * http://www.gdal.org/ogr/ > OGR Supported Formats, u.a. [[INTERLIS]]: http://www.gdal.org/ogr/drv_ili.html |
− | + | ||
+ | ogrinfo-Dokumentation: | ||
+ | * http://www.gdal.org/ogr/ogrinfo.html | ||
== Beispiele == | == Beispiele == |
Version vom 30. Oktober 2007, 23:00 Uhr
OGR Simple Feature Library: OGR Simple Features Library is a part of the GDAL library which is part of FWTools.
OGR is a C++ open source library (and commandline tools like OGR2OGR) providing read (and sometimes write) access to a variety of vector file formats including Shapefiles, Mapinfo mid/mif and TAB formats.
Siehe auch:
Inhaltsverzeichnis
Software
- OGR wird als Teil der FWTools verteilt (Linux und Windows-Version])
ogr2ogr und ogrinfo
ogr2ogr-Dokumentation:
- http://www.gdal.org/ogr/ogr2ogr.html
- http://www.gdal.org/ogr/ > OGR Supported Formats, u.a. INTERLIS: http://www.gdal.org/ogr/drv_ili.html
ogrinfo-Dokumentation:
Beispiele
Konvertiere INTERLIS 1 nach Shape
Konvertieren von INTERLIS 1-Dateien (.itf und .ili) nach Shapefile.
- Input: ili-bsp.itf and ili-bsp.ili
- Resultat: Für jede INTERLIS 1-Tabelle wird ein Shapefile(-Paar .shp/.dbf) erzeugt im Output-Verzeichnis shpdir/
% ogr2ogr -f "ESRI Shapefile" shpdir ili-bsp.itf,ili-bsp.ili
- Hinweise:
- Es wird immer ein .dbf erzeugt, auch wenn keine Sachdaten vorhanden sind.
- Fehlt die .ili-Datei muss diese zuerst organisiert werden. Gelingt dies nicht, bleibt nichts anderes, als diese zu erraten. Evtl. hilft OGRINFO.
- Die Erzeugung von Sichten (JOINs) aufgrund von Beziehungen zwischen Tabellen sind nicht Bestandteil einer Datenbeschreibung und der Daten.
- Speziell: Beschriftungen werden in separaten Tabellen verwaltet. Das bedingt eine nachträgliche Bearbeitung (Konverter wie FME machen das im Rahmen des Konvertierung-Schrittes).
- Unter Windows ev. setfw.bat ausführen, damit die Programme im System-Pfad sind und gefunden werden.
Zeige alle Attribute eines Shapefiles
Mit dem Tool ogrinfo kann man Schema-Informationen über die unterstützten Formate abfragen.
ogrinfo -so -al Bahnhoefe.shp
Weblinks
- OGR Simple Feature Library Home (=> FWTools): http://www.gdal.org/ogr/