Open nebukadnezar opened 6 years ago
It's correct as SDF longitudes are positive westings. https://github.com/jmcmellen/splat/blob/master/utils/srtm2sdf.c#L550
That is a surprising explanation. And I'm not being cynical, I'm genuinely surprised by this, and here's why: Considering plotting a topo map with the filenames changed to the actual longitudes as I suggested above in fact does create the topo map, with the correct orientation. When I leave the filenames the way they were generated, no tiles are found, and, consequently, no topo map is created. However, that, along with the absence of any mention that longitudes are in fact NOT longitudes but eastings, led me down the wrong path.
And it's snake potion units again that are causing grief - and this time in a particularly mischievous way: latitude and longitude are well established terms with globally accepted meaning. If one substitutes one of the coordinates with a different unit, a different name should be used. Call it an easting, not a longitude. If only the world could agree one day on using the same units for the same things all over the place...
running the SDF converter for files in Australia: srtm2sdf S31E113.hgt
creates this output file:
-31:-30:246:247.sdf
The correct filename would be: -31:-30:113:114.sdf
This behaviour occurs both on OS X and Ubuntu 16.04. I've built from the git source on both platforms, and I've also tried the pre-compiled OS X binary. They all behave the same.