Download DEMs from the Spanish National Geographic Institute easily. See the live app here.
This project uses svelte-kit. To start developing do npm install
and npm run dev
.
The scripts for obtaining and cleaning the data are on the scripts
folder. For using the imagery you have to accept the terms of the CC-BY licence.
These are common GDAL commands you can use to work with this imagery. You can find more in this cheatsheet.
Merge rasters
gdal_merge.py -o merged.tif input1.asc input2.asc
Add geographic information
For some reason QGIS doesn't recognise the coordinate system of these files straight away. To fix this we can look at the UTM zone of our map, see to what EPSG code from this list corresponds (remember these files are usually ETRS89) and use gdalwarp.
This is how we add geographic metadata to a UTM30 tile:
gdalwarp -s_srs "EPSG:25830" -t_srs "EPSG:25830" merged.tif reprojected.tif