Package org.gdal.gdal

Class RasterAttributeTable

java.lang.Object
org.gdal.gdal.RasterAttributeTable
All Implemented Interfaces:
Cloneable

public class RasterAttributeTable extends Object implements Cloneable
The RasterAttributeTable (or RAT) class is used to encapsulate a table used to provide attribute information about pixel values. Each row in the table applies to a range of pixel values (or a single value in some cases), and might have attributes such as the histogram count for that range, the color pixels of that range should be drawn names of classes or any other generic information.

The RasterAttributeTable class is a binding for the C++ GDALRasterAttributeTable class.

Raster attribute tables can be used to represent histograms, color tables, and classification information.

Each column in a raster attribute table has a name, a type (integer, floating point or string), and a GDALRATFieldUsage. The usage distinguishes columns with particular understood purposes (such as color, histogram count, name) and columns that have specific purposes not understood by the library (long label, suitability_for_growing_wheat, etc).

In the general case each row has a column indicating the minimum pixel values falling into that category, and a column indicating the maximum pixel value. These are indicated with usage values of GFU_Min, and GFU_Max. In other cases where each row is a discrete pixel value, one column of usage GFU_MinMax can be used.

In other cases all the categories are of equal size and regularly spaced and the categorization information can be determine just by knowing the value at which the categories start, and the size of a category. This is called "Linear Binning" and the information is kept specially on the raster attribute table as a whole.

RATs are normally associated with Bands and be be queried using the Band.GetDefaultRAT() method.