Annotated Chapter List

This annotated list of chapters from The Geospatial Desktop provides a brief synopsis of what you’ll find in the book.

This chapter sets the stage for the book and gives you a bit of a preview of what’s coming up in the following chapters. An example of a typical mapping problem is presented—through the eyes of an avid bird watching character.
Getting Started
Do a bit of self-assement to determine what type of user your are—beginner, intermediate, or advanced. This will help you determine which software you will meet your needs. We also take a look at choosing an operating system, selecting the right tools, and how to get the software downloaded and installed.

Integration of tools and managing change is an important consideration, whether you are using open source or proprietary software. This chapter provides some guidance on these issues, as well has how to get support for OSGIS software.

Having mapping software without data isn’t much good. We take a brief look at where to find data to meet your needs.

Working with Vector Data
Now we get down to using some software. This chapter takes a look at working with vector data using OSGIS.

Viewing data is like the “Hello World” application that everyone writes when learning a new programming language. It’s the first thing you’re going to want to do with any GIS application. In this chapter we take a look at not only viewing, but also how you can use renderering techniques to convey information about the relationships and characteristics of your data.

Before leaving this topic, we explore using OSGIS to view and work with the attributes associated with your data, including some interesting techniques to make it work for you.

This chapter makes use of uDig and Quantum GIS, as well as ogrinfo.

Working with Raster Data
Raster data is everywhere in the GIS world. You can use it as a background layer for your vector data or do full-blown analysis with it. In this chapter our goal is to get you up and running with raster data.

We start with simple viewing of rasters and also examine how to improve the rendering performance through the use of pyramids or overviews.

Rasters are more than just pretty pictures and to prove it we take a look at some additional types that can be used for analysis, including Digital Elevation Models (DEM) and grids.

In this chapter we use of some of the fine GDAL utilities as well as Quantum GIS.

Digitizing and Editing Vector Data
Creating data by digitizing is a common requirement, even for a casual user of GIS. In this chapter we take a look at simple digitizing, as well as editing the attributes associated with your points, lines, and polygons.
Data Formats
One of the challenges in working with GIS software, whether it be proprietary or open source, is making sense of the many data formats you encounter. This chapter takes a look at some of the common formats you will encounter so you can get an idea of what’s out there. We’ll also look at where these data formats come from, some of the conversion options, and lastly how to choose a standard data format for your mapping projects.

Spatial Databases
In this chapter we take a look at spatial databases. A spatial database allows us to store features, display them, or perform geoprocessing and analysis through a rich set of spatial functions.

We’ll compare the major spatial database offerings (PostgreSQL/PostGIS and MySQL) to get an idea of which is for you.

From there we’ll look at getting started with PostGIS and how to use it with both uDig and Quantum GIS.

Creating Data
Using existing data is fine and provides a lot of capability—until we want to display data specific to our area of interest. Sometimes we luck out and find the data; other times we have to create or convert it. At some point in your OSGIS career, you are going to need to do some creation or conversion of data to get what you need. This is where you move on from the hunter-gatherer stage in your GIS data usage.

In this chapter we’ll explore some of the ways in which we can torture data (whether raw or cooked) into submission and make it usable. Some of the methods include digitizing, importing from text files or other sources, converting data, importing GPS data, and georeferencing an image.

Projections and Coordinate Systems
If the world were flat it would be a lot easier —at least on map makers. Unfortunately that’s not the case so we’re faced with the age-old problem of depicting features on a spheroid (that’s the earth) on a flat piece of paper (or screen).

There are plenty of books and online resources that delve into the details of projections and datums. Our goal in this chapter is to give you a brief yet practical introduction to provide what you need to know to work with your data. At the end of the chapter you’ll find some additional resources you can use to learn more about the sometimes complex world of projections and coordinate systems.

It’s often not enough to have data and look at it. We almost always want to do some sort of manipulation or processing. This is where geoprocessing comes in. We’ll take a broad definition of geoprocessing to include any kind of data manipulation and analysis. To some extent you could consider importing data as a geoprocessing operation.

In this chapter we’ll look at some geoprocessing operations, including projection of data, line of sight analysis, watershed modeling, hillshading, clipping features, and grid algebra.

If you are wondering what tools are available in the OSGIS stack to accomplish these tasks, for the most part you’ll find the answer is GRASS. While some of the other desktop tools provide various levels of support for a few types of operations, GRASS provides the most complete and powerful toolset. The goal in this chapter is not to instruct you in the use of all the GRASS geoprocessing tools, but rather introduce you by way of example to the possibilities.

Using Command Line Tools
Command line tools provide a powerful way to manipulate data, especially when you want to process in batch using a script. This chapter describes some of the more common and useful command line tools and illustrates how to use them to perform common data manipulation, conversion, and map generation tasks.

We start with a look at Generic Mapping Tools (GMT), which allow you to create cartographic quality maps from the command line. This sounds simple but in fact it has quite sophisticated features including base map creation, plotting x-y values, lines, and polygons, coordinate transformations, gridding, contouring, and 3D illuminated surfaces.

For exploring, transforming, and converting raster and vector data we’ll take a look at the GDAL/OGR suite of utilities.

Lastly we look at PostGIS and the shp2pgsql and pgsql2shp utilities for importing and exporting shapefiles.

Getting the Most out of QGIS and GRASS Integration
In this chapter you will see how QGIS can serve as a front-end for viewing and editing GRASS data, as well as performing analysis and data conversion.

QGIS supports GRASS through the use of a plugin. The plugin provides access to GRASS data and functions and is distributed with all official QGIS packages.

Examples included in this chapter include loading and viewing GRASS data, editing GRASS data with QGIS, and using the QGIS-GRASS toolbox, a powerful set of analysis and conversion tools.

GIS Scripting
Most GIS users that I know end up doing a bit of programming, regardless of the software they are using. There is always some little task that is easier done with a script or a bit of code. In this chapter we’ll take a look at some methods for automating tasks in OSGIS software. You don’t have to be a programmer to do a bit of script writing, especially when you can get jump-started by downloading examples and snippets. The script languages available to you depend on the application you are using. Applications and tools with a command line interface (CLI) can be scripted with most any language available. Others have bindings for specific languages. Some non-exhaustive examples include:

  • GRASS – shell, Tcl/Tk, Perl, Ruby, Python
  • QGIS – Python
  • GDAL/OGR – shell, Perl, Ruby, Python
  • PostGIS – any language that works with PostgreSQL, including Perl, Python, PHP, and Ruby

Some OSGIS applications even provide bindings that allow you to write a custom application using a language such as Python. This chapter explores some of the techniques used with these applications.

Writing Your Own GIS Applications

Most GIS users have ventured into the realm of programming—whether it be writing scripts or full-blown applications. Scripting is quite useful for automating GIS tasks.

Sometimes you find yourself in a position where you need a customized application. The full version of your favorite OSGIS application is overkill or doesn’t provide the features you need. Often trying to twist the application into the form you need results in a system that is user-unfriendly and difficult to use. Many disciplines can benefit from a lightweight custom application that serves a specific need. These are the reasons for writing such an application. This chapter looks at the options for writing an application using open source components such as QGIS.

Survey Of Desktop Mapping Software
There are a lot of applications in the OSGIS desktop world. In this chapter we’ll explore some of the major choices available. In our survey we’ll classify applications based on both capability and the underlying language. The programming language behind an application is important because it affects how the application is distributed, installed, and how easy it is for us to customize.

For most people, the words “Desktop GIS” generally conjure up visions of a GUI interface. While that’s largely true, it’s clear there are command line applications that deserve a place in our toolkit. In the survey, we’ll divide the applications into two primary groups—those with a GUI and those that are command line only.

The survey includes:

  • GMT
  • gvSIG
  • Jump/OpenJump
  • OpenEV
  • QuantumGIS
  • Thuban
  • uDig
Installing Software
In this appendix you will find brief information on installing most of
the applications discussed in the book. As always, it helps to read the
installation instructions provided with the software. This information
is of the quick-start variety and will help you get up and running.
We provide information for each platform, assuming of course that the
application is supported on each:

  • OpenJump
  • Quantum GIS
  • uDig
  • GMT
  • FWTools
GRASS Basics
Once you have GRASS installed, setting up GRASS and creating your locations is key to getting off the ground. This appendix will guide you through creating a location using both QGIS and the GRASS shell. From there you’ll get a basic introduction to working with GRASS GIS to view and edit data as well as an introduction to the GUI.
Quantum GIS Basics
Quantum GIS has a lot of functionality and many areas to explore. This appendix provides an introduction to the basics of using QGIS, including map navigation and other essential features.