The shaded relief technique is a method for representing the topography which is prettier and intuitive.

I found some examples about doing them with d3js, but required a previous preparation with gdal. I wanted to show how to create the effect using the DEM file directly. I added the tutorial to the d3-raster-tools-docs tutorial.

The result:

  • [The code explanation](/d3-raster-tools-docs/plot/shaded-relief.html)
  • [The source code](/d3-raster-tools-docs/code_samples/dem-shaded-page.html)
  • [How to get the data](/d3-raster-tools-docs/code_samples/swiss-page.html)