Hello,
I'm using gdalbuildvrt to create a virtual raster from multiple tiff tiles.
I need the output virtual raster to have an alpha band, and as I do not
know beforehand if the input rasters will contain one or not, I use the
'addalpha' option of gdalbuildvrt to add one if needed.
As I understand the documentation of gdalbuildvrt, 'Adds an alpha mask band
to the VRT when the source raster have none' means that if the source
rasters already have an alpha band, no new band should be added.
However, when I run the following command on the attached test files (that
already contain an alpha band) :
gdalbuildvrt -addalpha test.vrt 1.tiff 2.tiff
The result vrt contains a fifth band, and thus two alpha bands.

Do I misunderstand the gdalbuildvrt documentation, or is there a problem
with my input files ?

I tested this with GDAL v3.0.4 provided in the ubuntu 20.04 repository, as
well as with GDAL v3.6.0dev-cc78d80d5df3750db317b96d93013d5f70ef6f0a from
the osgeo/gdal:latest docker image.

Thanks.
_______________________________________________
gdal-dev mailing list
gdal-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/gdal-dev

Reply via email to