[gdal-dev] Possible issue with alpha band and VRT

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

[gdal-dev] Possible issue with alpha band and VRT

jratike80

Hi,

 

I repeated the steps which are described in this question https://gis.stackexchange.com/questions/317916/gdalbuiltvrt-output-is-different-than-the-source-images-when-using-dstalpha and it indeed seems that transparency that is defined with an alpha band in original images is lost if I read data through VRT. I wonder if something similar happens than in this issue https://github.com/mapbox/rasterio/issues/1454 with GDALRasterBand::GetMaskBand().

 

-Jukka Rahkonen-


_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev
Reply | Threaded
Open this post in threaded view
|

Re: Possible issue with alpha band and VRT

Even Rouault-2
Jukka,

> I repeated the steps which are described in this question
> https://gis.stackexchange.com/questions/317916/gdalbuiltvrt-output-is-diffe
> rent-than-the-source-images-when-using-dstalpha and it indeed seems that
> transparency that is defined with an alpha band in original images is lost
> if I read data through VRT.

gdalbuildvrt doesn't do alpha compositing (yet?). It you stack several images,
the non-alpha and the alpha band of the latest appearing in the sources will
be used, overriding completely what is beneath.
gdalwarp will do the right thing.

> I wonder if something similar happens than in
> this issue https://github.com/mapbox/rasterio/issues/1454 with
> GDALRasterBand::GetMaskBand().

From a very quick look, no. The rasterio issue is about 16-bit images and mask
band

Even

--
Spatialys - Geospatial professional services
http://www.spatialys.com
_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev