[Qgis-developer] Should QGIS use generic names for raster bands

Peter Ersts ersts at amnh.org
Fri Jul 18 11:50:31 EDT 2008


Howdy devs.

A comment on the recent ticket has gotten me thinking. Should QGIS use 
generic names (i.e., Band 1, Band 2 etc) rather than using the band 
names stored in the raster file itself?

Take these two geotiffs. They are the same data (Landsat band 1,2,3,4,5, 
and 7 in that order) but were created with two different applications. 
Here are the band names as reported by GDAL

GeoTiff_ENVI:
Band 1 Block=256x1 Type=Byte, ColorInterp=Red
Band 2 Block=256x1 Type=Byte, ColorInterp=Green
Band 3 Block=256x1 Type=Byte, ColorInterp=Blue
Band 4 Block=256x1 Type=Byte, ColorInterp=Alpha
Band 5 Block=256x1 Type=Byte, ColorInterp=Undefined
Band 6 Block=256x1 Type=Byte, ColorInterp=Undefined

GeoTiff_ERDAS
Band 1 Block=256x32 Type=Byte, ColorInterp=Gray
Band 2 Block=256x32 Type=Byte, ColorInterp=Undefined
Band 3 Block=256x32 Type=Byte, ColorInterp=Undefined
Band 4 Block=256x32 Type=Byte, ColorInterp=Undefined
Band 5 Block=256x32 Type=Byte, ColorInterp=Undefined
Band 6 Block=256x32 Type=Byte, ColorInterp=Undefined


So,
1) Displaying undefined in the pull down menu for a band name does not 
seem very useful to me
2) The user/application that created the raster file can change the name 
of the bands and they may not be accurate. In the GeoTiff_ENVI example, 
Band 1 is Landsat Band 1 which is actually the blue band. This could be 
confusing to newer users
3) In the GeoTiff_ERDAS example, if you wanted a true color combination, 
your pulldowns would display R= 3: Undefined G=2: Undefined B=1: Gray. 
Again, the band names from the raster file are not very useful.

If we are to go with generic band names, I will not be winning any 
popularity contests with the users because the band name is stored in 
the project file rather than just the band number. While it may seem 
trivial, I think that this is actually a very important decision as we 
move toward trying to get version 1.0 out.

Any thoughts?

-pete

-- 
====================================
Peter J. Ersts, Project Specialist
American Museum of Natural History
Center for Biodiversity and Conservation
Central Park West at 79th Street
New York, New York 10024
Tel: Home Office (518)-632-4745 or NYC Office (212)-496-3488
Web: http://biodiversityinformatics.amnh.org
Web: http://cbc.amnh.org

Quantum GIS Raster Development Team. Visit http://www.qgis.org
to learn more about QGIS, a free and open source desktop GIS

Open Source,
...evolving through community cooperation to change the world bit by bit



More information about the Qgis-developer mailing list