This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.
Pages1
#1
MAPAS/MAPS / Re: Understanding oruxmaps offline raster format (sqlite)
September 18, 2019, 06:31:22 AM #2
MAPAS/MAPS / Re: about altitude precision in DEM file formats
September 18, 2019, 06:25:21 AMTo find out how to get DEM data other than SRTM data into Oruxmaps, I first looked at converting the SRTM HGT files to DEM+HDR. This allowed me to better understand when the conversion was successful, as I could always go back to the underlying HGT file for comparison. HGT files almost identical to BIL files, without a separate header; a hex comparison shows that there are differences, and you cannot simply rename HGT as BIL. The coordinates for an HGT file come from the file name, so if you change the name the file will either fail to load or load in a different position.
Most software converting HGT files modifies the data file slightly and writes a header that may or may not work with Oruxmaps. Here is how to make sure it works for your data.
For example GDAL conversion to BIL+HDR in QGIS changes the HGT ULYMAP to reflect the starting point and loads almost correctly in QGIS, so seems to be a reliable utility. The only error is taking the cell corner and not the cell centre as the starting point. ER Mapper writes a header that correctly interprets the cell coordinates with a note "# registration point is center of lower-left cell", and correctly assigns the coordinates to the middle of the cell, but does not generate the correct HDR for a BIL. However, this can be rewritten to make it work by simply following the model HDR from GDAL. Landserf does not write a BIL that can be read, regardless of editing the header. Other software may do the job, such as Ilwis and Saga, or you may have access to high end software such as MapInfo and ArcGIS. The principles will be the same; does the software write the correct data and header file?
The key to success seems to be a good HDR file, which can be summarized using this example of Lidar data from an historic gold mining area in Tasmania:
BYTEORDER I
NROWS 2703
NCOLS 3695
NBANDS 1
NBITS 16
ULXMAP 147.036925
ULYMAP -43.190753
XDIM 9.9999999999973581e-006
YDIM 9.9999999999986354e-006
The data file is 34Mb, and the data are freely available online, so let me know if you want a copy.
The process that seems to work most reliably is using the QGIS GDAL Warp (reproject) to get any dataset in WGS84, then QGIS GDAL convert to produce the BIL(DEM)+HDR that Oruxmaps needs. The only problem I have encountered is that HGT files will take precedence over DEM+HDR files, so you will have to remove or disable (rename) HGT files in an area of interest.
Pages1