HGT import with gradient mapping included
@Jehan
Submitted by Jehan Link to original bug (#791485)
Description
HGT files are imported as special-case in: plug-ins/common/file-raw-data.c See bug 771661.
HGT values are stored on 16-bit signed integers which are immediate elevation values in meters. It means a single value ranges from -32767 to 32767 meters, with the special exception of -32768 being an "error" value.
First consequence is that on earth reliefs, most pixels will be concentrated around gray 0.5 (see level). Highest peak (Everest, 8848m) will be gray 0.635. That makes quite low contrast images by default, which is quite annoying since it may look like import didn't work unless you specifically read about this format specifics. You will need to use "map gradients" for instance to see finally something. An improvement like bug 791458 would help a lot.
Yet even so, you still need to understand the format to create a useful gradient, and will probably have to edit the gradient file if you want accurate mapping of colors to elevations.
Ideally you could map a gradient at import time, and GIMP would convert gradient [0;1] range and show only meters. Therefore someone who opens a HGT file could choose the color for error pixels, then various color ranges to elevation ranges in meters with appropriate immediate preview.
Version: git master