[gdal-dev] pyramids on vrt or individual tiffs?

Even Rouault even.rouault at spatialys.com
Tue Jun 28 09:42:48 PDT 2016


Hi Trent,

>     Quick question. I am building a vrt (gdalbuildvrt) from high-resolution
> tiffs which are regionally very discrete (islands). Should I (1) build
> pyramids on the vrt which would be very large given the amount of nodata
> between the images or (2) build pyramids on the Tiffs.

> For the second case,
> will program like mapserver use the pyramids from the individual Tiffs when
> accessing the vrt?

Yes (that will be handled transparently by GDAL to be more exact)

(2) will save you a lot of storage space, but if you unzoom a lot, up to the point of
having all individual tiffs in the view extent, they will have to opened all to get the few pixels
needed to make the mosaic, which might be slow if there are many individual tiffs.

A better solution would be a (1'), that will be the GeoTIFF driver improved to be able
to create sparse tiles

Or with some scripting, you could :
- create an empty .vrt.ovr that is a TIFF of VRT_width/2 x VRT_height/2 with -co SPARSE_OK=YES
- gdalwarp each tiff into it with -wo SKIP_NOSOURCE=YES
- repeat for each overview level : .vrt.ovr.ovr for ovr_factor = 4, .vrt.ovr.ovr.ovr for 8, etc...

Even

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


More information about the gdal-dev mailing list