[Gdal-dev] ENVI and raster attributes/color support

Vincent Schut schut at sarvision.com
Wed Nov 10 07:24:26 EST 2004


Frank Warmerdam wrote:
> Markus Neteler wrote:
> 
>> Hi,
>>
>> I have written (hope I got it right) a BSQ header file
>> for
>>
>> http://glcf.umiacs.umd.edu/data/landcover/data.shtml
>> AVHRR Global Land Cover Classification
>>
>> The attached file is a header file for 
>> "gl-latlong-1km-landcover.bsq.gz" from:
>> ftp://ftp.glcf.umiacs.umd.edu/glcf/Global_Land_Cover/Global/gl-latlong-1km-landcover/ 
>>
>>
>> My question is if support could be added to GDAL to read
>> the color table and the raster attributes so that I could
>> generate a more GIS convenient IMG file or whatever. Or is it a 
>> complicated thing (or "quota exceeded" for me :-)?
> 
> 
> Markus,
> 
> I have implemented support for reading the "class lookup" as a colormap for
> the first band, and capturing the "class names" as category names returned
> by the GDAL GetCategoryNames() method.
> 
> I doubt the class/category names will do you much good as I am unaware 
> of any
> utility other than gdalinfo that does anything with category names.
> 
Dear Frank, Markus, others,

would it be possible to implement GetCategoryNames() support for a 
grass57rasterband? I think it might be relatively easy, as grass already 
supports this using G_read_cats function (see 
http://mpa.itc.it/markus/grass50progman/node136.html), but I'm not very 
good in C...
Though there's limited client support for this feature, I hope to be 
able to use it from my own Python scripts.

Regards,
Vincent.



More information about the Gdal-dev mailing list