Raster GIS

Terrain analysis with slope, hillshade and contours

Derive slope, aspect, hillshade and contour lines from a digital elevation model, and understand the z factor and units.

Intermediate2 min read

You will learn

  • Compute slope and hillshade.
  • Generate contour lines.
  • Understand z factors and units.

Prerequisites

Data for this tutorial

DEM 30 m (synthetic) Download dem.tif

Format
GeoTIFF, 1 band, Float32
Geometry
Raster, 560 × 480 cells of 30 m
CRS
EPSG:32643 (WGS 84 / UTM zone 43N)
Content
Elevations 450.01 to 678.95 m; NoData -9999 in the south-west corner
In Orbis
Browser panel ▸ Tutorial sample data (synthetic) ▸ DEM 30 m, or Load complete tutorial pack.

Licence: CC0 1.0. All tutorial data is synthetic and generated by Orbis. About the datasets

The task

From the DEM you want a shaded relief to show the landform, the slope in degrees, and contour lines every 25 m.

Steps

  1. Add DEM 30 m from the tutorial data.
  1. In the Toolbox, open Hillshade, choose the DEM as Elevation raster (DEM), keep Sun azimuth 315 and Sun altitude 45, and click Run. Place the hillshade under the DEM in the Layers panel and lower the DEM's opacity for a relief map.
  1. Open Slope, choose the DEM, keep Output units at Degrees and click Run.

    Slope of the DEM in degrees, from pale (flat) to dark red (steep), with contour lines every 25 m on top
    Slope and 25 m contours.
  1. Open Contour lines, choose the DEM, type 25 as Interval and click Run. Each line has the elevation in the elev field; label the layer with it.

Expected result

A hillshade, a slope raster from 0° to about 16.5° (median about 1.1°: the district is gently sloping), and 30 contour lines.

Common mistakes

  • Elevations in feet. With the default Z factor of 1, a DEM in feet gives slopes that are too steep. Set the factor to 0.3048.
  • Edges and NoData. Cells next to NoData or the raster edge have no complete neighbourhood and become NoData.

Troubleshooting

  • Too many contours. Increase the interval; a small interval on a rough DEM produces many short lines.