[gdal-dev] The histogram results from a vrt datsource when the rasters are partially overlapped

Even Rouault even.rouault at spatialys.com
Thu Sep 3 01:27:21 PDT 2015


Le jeudi 03 septembre 2015 09:03:29, Andrea Peri a écrit :
> Hi,
> I have a VRT datasource, with more raster inside.
> Each raster is partially overlapped to the two near rasters.
> 
> My dubt is how the histogram retrieved using the API GetDefaultHistogram,
> is counting the overlapping.
> 
> Infact the overlapping portin is more NULL values, but also there is
> portion f informations.
> 
> Is in a pixel overlapped there is a NULL from frame1 and a VALUE from
> frame2. I could guess the Histogram ignore the NULL from frame1 and count
> only the VALUE from frame2.
> 
> But when the frame1 and frame2 give the differents values: VALUE1 and
> VALUE2. In this case what is the value counted in the histogram ?
> 
> It count the top level raster only, the first raster only, use a mean
> of both or count both duplicating so the number of cell in the results
> ?

Andrea,

Hopefully (and that's what the existing code is supposed to do), the histogram 
reported on the VRT should be the same as the one you would get on a GeoTIFF 
that would result from the conversion of the VRT. Said other wise, it should 
be the histogram of what is displayed.

Even

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


More information about the gdal-dev mailing list