itinero / srtm

A library to load SRTM data and return heights in meter.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Support for SRTMv4 data

themohitkhare opened this issue · comments

They have released newer SRTM data, Is it possible to add local data support?
https://cgiarcsi.community/data/srtm-90m-digital-elevation-database-v4-1/

This is definitely possible but I personally don't have the time right now. Pull-requests welcome! 👍

I was thinking the same thing, but they have changed the file format for the version 4. Need some help in how can I parse this latest format.

Is the current way of doing things broken because of some hardcoded URL? We host the source data on our own server so we don't notice any changes to the source data.

If you have some code example somewhere that can parse this new format, please post it here (doesn't have to be C#).

The data is ACSII file, with a 2d array holding the elevation data. But It would take some time to understand as it is all new to me. I believe the tiles contains latitude and longitude data.

https://drive.google.com/drive/folders/17dnXkQKlF_fcqqETrHco5cVfF3R7kty0

Hi ! The data is in Esri Ascii Grid format, well documented. (see here)
I have coded a reader here if you are interested : https://github.com/dem-net/DEM.Net/blob/46c8546117d51b3485912e9f1568587760dfa2c4/DEM.Net.Core/IO/Raster/AsciiGridFile.cs

I tried the above reader, but it seems like the SRTM class is tightly coupled with the .hgt type used in SRTMv3. Either I would have to change the entire structure, or @xivk can add better structure allowing easy compatibility with SRTMv4 ACSII structure.
Maybe further abstraction is the way to go.