[gdal-dev] gdalbuildvrt and nulls again - now from Photoshop

William Kyngesburye woklist at kyngchaos.com
Fri Jul 10 15:14:18 EDT 2009


This time I'm taking some Photoshop-created tiffs that I georeference  
with a TFW.  These tiffs I save with transparency mask (not layers) to  
handle nulls.

Reported by gdalinfo, they appear as:

Band 1 Block=12775x5 Type=Byte, ColorInterp=Red
   Mask Flags: PER_DATASET ALPHA
Band 2 Block=12775x5 Type=Byte, ColorInterp=Green
   Mask Flags: PER_DATASET ALPHA
Band 3 Block=12775x5 Type=Byte, ColorInterp=Blue
   Mask Flags: PER_DATASET ALPHA
Band 4 Block=12775x5 Type=Byte, ColorInterp=Alpha

But when I run gdalbuildvrt on them, they are skipped:

gdalbuildvrt does not support heterogenous band numbers. Skipping  
[sometiff].

If I save it with layers instead of transparency, GDAL doesn't see the  
alpha mask on the layer:

Band 1 Block=12775x6 Type=Byte, ColorInterp=Red
Band 2 Block=12775x6 Type=Byte, ColorInterp=Green
Band 3 Block=12775x6 Type=Byte, ColorInterp=Blue


Is there a way I can get gdalbuildvrt to recognize the transparency as  
null, without converting them with gdal_translate first?  Maybe a  
different way to save the tiff with a mask from Photoshop?

Does the vrt format support a tiff transparency mask as null (and it's  
just gdalbuildvrt that doesn't)?

-----
William Kyngesburye <kyngchaos*at*kyngchaos*dot*com>
http://www.kyngchaos.com/

"History is an illusion caused by the passage of time, and time is an  
illusion caused by the passage of history."

- Hitchhiker's Guide to the Galaxy




More information about the gdal-dev mailing list