HFA driver: Histogram column uses GFU_PixelCount on writing, but not on reading
|Reported by:||nflood||Owned by:||warmerdam|
When creating a column in a raster attribute table with the HFA driver, setting eFieldUsage=GFU_PixelCount will force the column to be called "Histogram", which is consistent with Imagine's conventions (HFA has no explicit column usage mechanism, just reserved column names). However, when reading the Histogram column, the usage in the GDALRasterAttributeTable is set to GFU_Generic. I believe this should set it to GFU_PixelCount, in order that one can generically find this column by using GetColOfUsage?().
In the current trunk, in hfadataset.cpp, compare line 561 (for reading) with line 1605 (for writing).
Attached is a patch against the current trunk (2014-01-20), which fixes line 561. Also attached is a patch against the 1.10.1 release (line numbers are wildly different), in case anyone needs it.