4

Does anyone know if it's possible to add a TIFFTAG when saving a TIFF file (I'm using the C/libtiff interface) that will give a name to each band?

Some kind of per-band TIFFTAG_IMAGEDESCRIPTION is what I'm after. I checked the documentation but can't find anything - however, I have seen TIFFs saved with band names so I assume it's possible somehow.

I am not using rasterio.

os1
  • 328
  • 1
  • 14
  • I thought this looked like it might be off-topic but since Remote Sensing is on-topic the library being asked about appears to be too: http://www.remotesensing.org/libtiff/ – PolyGeo Jul 28 '15 at 11:09
  • I posted here as I've only ever seen per-band names for RS data: Usually a name with the central wavelength of other important feature of the channel. – os1 Jul 29 '15 at 08:00
  • It sounds to me a bit like a simplified case of Raster Attribute Table (RAT). GDAL seems to support them only for Idrisi, GeoRaster, KEA and HFA (Erdas) formats. However, if TIFFTAG_IMAGEDESCRIPTION is enough for you it can be handled with the GDAL GeoTIFF driver http://www.gdal.org/frmt_gtiff.html. Reading the source code can help you with your own programming. – user30184 Jul 29 '15 at 09:50
  • Thanks, but I'm already using that tifftag. I'm beginning to think that the files I saw with per-band names were using some very software-specific thing. Can't find any more info about them. – os1 Jul 29 '15 at 19:51

0 Answers0