Geography Reference
In-Depth Information
10.1
Projecting Data
That's right—we're going to take one more look at projecting data, even
though we've given it a good going over in Chapter 9 , Projections and
Coordinate Systems, on page 138 . Once again, depending on how you
view and use your GIS data, you may find you need to project the data
to another coordinate system to make your life easier. Some of the desk-
top GIS applications support “on-the-fly” projection of data. This means
you set the default projection for the map, and every layer that is added
is reprojected to that coordinate system, assuming it's different from
the default. This is a two-edged sword. On one hand, it's very conve-
nient. On the other, there is a performance penalty in that every point
or vertex must be transformed as the features are drawn. The size of
the penalty depends on a number of factors and really can't be gen-
eralized; however, suffice it to say that as long as you're transforming
coordinates on the fly, it's going to be slower.
As we've seen, the solution is to transform the data to a coordinate sys-
tem that is suitable for your project work. In Section 11.2 , Coordinate
System Conversion, on page 194 , you'll see how to use ogr2ogr to trans-
form OGR-supported layers. In this section, we'll look at how to change
the coordinate system of our data using GRASS.
GRASS has two commands that are used to project data: r.proj for raster
maps and v.proj for vector maps. The key to projecting data is having
your locations properly defined and set up. If you need a hand getting
started with GRASS locations and mapsets, take a look at Section C.1 ,
Location, Location, Location, on page 296 .
When you project a map, it ends up in your current location and map-
set. You could think of it as copying the map from its original location
to your current one, transforming the coordinates as it goes. You don't
specify any projection parameters when projecting GRASS maps, since
all keys on the locations involved and locations always have a projec-
tion/coordinate system defined.
Let's look at the usage for projecting a vector map using v.proj :
> v.proj help
Description:
Allows projection conversion of vector files.
Keywords:
vector
 
 
 
Search WWH ::




Custom Search