[gdal-dev] Distinguish between no DTED data and actual DTED elevation of 0

Even Rouault even.rouault at spatialys.com
Wed Jun 26 04:40:35 PDT 2019


On mardi 25 juin 2019 19:57:11 CEST LEGGE Melvin wrote:
> Hi
> 
> I am a relative newbie to GIS programming so forgive me if I use the wrong
> terminology or don't state my problem in the most efficient GIS terms.
> Anyway, I have inherited a project written by an actual GIS person who is
> no longer with the company.
> 
> The DTED data consists of 4 GDalDatasets with actual DTED elevation data not
> reaching the boundaries of GDalDatasets - i.e., GDalDatasets are bigger
> than the actual DTED data.  Our program reads the elevation data along a
> bearing line from a given point to some requested distance, at regular
> intervals, by repeatedly calling GDALRasterBand->RasterIO for a specified
> distance.  What I am seeing is that elevation values of 0 are returned for
> points between the end of the DTED data and the end of the tile.
> 
> Is there any way I can distinguish between the situation above and an actual
> elevation of 0? 

No this looks like a "bug" in the data production itself. You could probably 
add your own custom logic to detect that situation and fix those 0 on the 
edges of the product to nodata (nearblack might be of help for this)

Even

-- 
Spatialys - Geospatial professional services
http://www.spatialys.com


More information about the gdal-dev mailing list