I have a DEM and a separate shapefile of all the roads within the bounds of the DEM. I want to combine the elevation data with the road data so that I can have the roads displayed with a graduated color symbiology based on the elevation of the road at any given point. Essentially a road map where the roads in the valleys are dark red and the roads on the summits are near-white, with a gradation for everything in between. Is this possible in QGIS?

  1. Split the roads into short segments, I use 20 m
  2. Drape to set Z of each road vertice from your DEM
  3. Symbolize your layer with graduated symbol, using the z values, for example with z_min($geometry)

enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.