Geoscience Reference
In-Depth Information
It is necessary to be aware that many GIS applications that support vector data
models also provide topology support for vector data. Topology is the study of the
relationship and adjacency of geometric vector objects. In GIS, topology refers to
the relative location of spatial objects regardless of their specific location. Topolog-
ical relationships (e.g. relative position, connectivity) are defined as relationships
between nodes, links and polygons. In most cases, topology is stored independently
of the coordinate and attribute data. For instance the topology associated with a line
includes the to- and from-nodes as well as the polygons located to its right and left.
There are many examples of where topology is used, for instance for network spa-
tial analysis or to detect digitizing errors that would cause gaps and slivers (small
spaces). Although GDAL/OGR does not inherently provide command line tools to
check and build topology, there is the possibility to use the GEOS library 1 in con-
junction with the OGR API using the Python bindings. GRASS GIS is an example
of a fully topological, open source GIS.
2.2 OGR Simple Features Library
There aremany toolkits and software packages that are available to process geospatial
vector data. Many of the translation packages, both proprietary and open source,
provide much of the same capabilities and functionality although their interfaces,
format support and cost all vary. Over the last decade, OGR has emerged as one of
the most stable libraries that supports a wide range of formats (both proprietary and
non-proprietary) as well as many spatial reference systems.
Although the OGR utilities only consist of a few command line utilities compared
to the many GDAL utilities, they provide a very rich set of functionality for managing
and processing vector spatial data:
To manipulate attribute and metadata of vector datasets;
To translate vector datasets between formats and spatial reference systems (pro-
jections);
To perform vector spatial analysis, such as vector overlays and creating spatial and
attribute subsets.
For the purposes of this chapter, we will describe the use of the command
line utilities from the OGR Simple Features Library ( ogrinfo , ogr2ogr and
ogrtindex ) using a subset of vector data from OpenStreetMap 2 for the region
of the Ile de France (Paris region). It is very easy to download OSM data from
the main website under the Export tab or from additional data providers that are
listed on the OSM wiki. 3 We will demonstrate how OGR can be used to process the
OpenStreetMap data format, referred to as the Protocolbuffer Binary Format (PBF)
1 http://geos.osgeo.org
2 http://openstreemap.org
3 http://wiki.openstreetmap.org/wiki/Downloading_data
 
Search WWH ::




Custom Search