[gdal-dev] Can VRT be used to control display order of images in mosaic?

Frank Warmerdam warmerdam at pobox.com
Tue Jun 22 11:16:14 EDT 2010


Roger André wrote:
> Hi All,
> 
> I'd like to control the order in which overlapping images are displayed 
> in a mosaic.  Is it possible to do that by using a VRT, and altering the 
> order in which the files are defined in it?
> 
> The online doc for gdalbuildvrt states, "If there is some amount of 
> spatial overlapping between files, the order may depend on the order 
> they are inserted in the VRT file, but this behaviour should not be 
> relied on."
> 
> Not sure if this disclaimer is for the gdalbuildvrt utility, or 
> describes the generic behavior of a raster VRT.

Roger,

I believe the statement applies to the VRT format itself.  I have looked
at the code, and it always applies them linearly based on the order they
appear in the .VRT list of sources.  I think you could depend on it "for now"
though in a future version we might do something more fancy that would
result in alternate ordering.

Best regards,
-- 
---------------------------------------+--------------------------------------
I set the clouds in motion - turn up   | Frank Warmerdam, warmerdam at pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush    | Geospatial Programmer for Rent



More information about the gdal-dev mailing list