9

Is it possible to make slope direction with QGIS 2.16.1 like in this image?

enter image description here

Global Mapper steps:

  1. Made grid point
  2. Apply slope direction.

enter image description here

I made point grid 100x100m and I used DEM layer. In Global Mapper software, there is a tool which make slope direction (flow direction) field, and then in QGIS I made this map. This is attribute table made with Global Mapper.

enter image description here

@lynxlynxlynx:This is result: Red arrows are old arrows and blue are new arrows. I think this is no what I want. Maybe red arrows are interpolated some slopes. You can see with contour lines that result is not good.

enter image description here

enter image description here

@SaultDon: There is uncovered areas on this image.

enter image description here

@lynxlynxlynx: it is similar enter image description here


I found tool for this. That is Saga plugin called: Gradient vector from surface.

11
  • 1
    Did you look at data-defined options for feature display? You can customise this under layer->preferences and choose different symbology. Aug 28, 2016 at 14:23
  • Not a problem with symbols, the problem is how to get data for slope direction. This field I made with Global Mapper. Is there option in QGIS?
    – nagib
    Aug 28, 2016 at 14:33
  • 1
    @nagib You could try r.flow or r.terraflow (for large rasters) to get flow direction. It requires GRASS GIS to be installed and configured in QGIS processing providers (Processing > Options > Providers).
    – SaultDon
    Aug 28, 2016 at 16:28
  • I was not able to generate r.flow and r.terra flow, there is something wrong with the parameters. My DEM terrain is GeoTIFF, is there a problem?Sometime ago I used to r.flow true path but the result was like a river down the hill. I prefer results with arrows.
    – nagib
    Aug 28, 2016 at 16:49
  • I made layer like terraflow and flow with other software and result is on the image below.
    – nagib
    Aug 28, 2016 at 17:24

2 Answers 2

8

I found tool for this. That is Saga plugin called: Gradient vector from surface.

enter image description here

And result is: you have to choose in style manager, arrow for lines

enter image description here

4
  • I have SRTM hgt files. How can I generate a map like this using QGIS ? I am on windows 7 and I have the latest version of QGIS. I do not see a option Gradient vectors from surface.
    – gansub
    Jun 29, 2017 at 13:54
  • docs.qgis.org/2.8/en/docs/user_manual/processing_algs/saga/… there is no such function gradient vector from surface
    – gansub
    Jun 29, 2017 at 13:55
  • It is SAGA plugin. In processing toolbox. In the search box you have to write, gradient vector, and that is it
    – nagib
    Jun 30, 2017 at 15:09
  • The tool "Gradient vectors from surface" is in the Saga toolset. It works really well but.... Clip your input raster to only the area you need. It requires trial and error runs to get the sizes and spread of the direction arrows exactly how you want it. Apr 22, 2018 at 14:58
7

You can generate the slope in several ways:

  1. Raster -> Analysis -> DEM -> Slope. Or via slope functions in the Processing framework (r.slope.aspect). Run it on your DEM. Do the same for the aspect.
  2. Create two new fields in your point layer (to hold the data).
  3. Use v.sample from Processing to assign values from the new rasters to your point layer. Or do it the long way by vectorizing the raster and then intersecting that with your point layer.

Note: To get correct results, I had to use the GDAL version of aspect calculator, the GRASS one was not satisfactory, similarly to your finding.

4
  • Testing doesn't give me satisfactory results though. My DEM is very dense (1x1m), but even with aggregated cells (10x10m), the aspect is mostly wrong and not just by an offset. Perhaps a bug, but I'm still on QGIS 2.14.3, not the latest one. Aug 29, 2016 at 16:35
  • 1
    Ok, found a solution — use the GDAL aspect Processing module instead of the GRASS one. Aug 29, 2016 at 17:17
  • Almost like original, but good result.
    – nagib
    Aug 30, 2016 at 16:57
  • The point grid looks shifted and considering the underlying cell size, that could account for all the differences. Aug 30, 2016 at 19:56

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