public class CoverageUtilities extends Object
| Modifier and Type | Field and Description |
|---|---|
static String |
COLS |
static String |
EAST |
static String |
MINX |
static String |
MINY |
static String |
NORTH |
static String |
ROWS |
static String |
SOUTH |
static String |
WEST |
static String |
XRES |
static String |
YRES |
| Modifier and Type | Method and Description |
|---|---|
static Number |
convert(Number val,
Class<? extends Number> type) |
static SimpleFeatureType |
createFeatureType(GridCoverage2D gc2d,
Class<? extends Geometry> geometryClass)
Creates a
SimpleFeatureType that exposes a coverage as a collections of feature
points, mapping the centre of each pixel as a point plus all the bands as attributes. |
static RangeLookupTable |
getRangeLookupTable(List<Range> classificationRanges,
int[] outputPixelValues,
Number noDataValue) |
static RangeLookupTable |
getRangeLookupTable(List<Range> classificationRanges,
int[] outputPixelValues,
Number noDataValue,
Class<? extends Number> clazz) |
static RangeLookupTable |
getRangeLookupTable(List<Range> classificationRanges,
Number noDataValue) |
static RangeLookupTable |
getRangeLookupTable(List<Range> classificationRanges,
Number noDataValue,
Class clazz) |
static RangeLookupTable |
getRangeLookupTableJAIEXT(List<Range> classificationRanges,
int[] outputPixelValues,
Number noDataValue,
int transferType) |
static HashMap<String,Double> |
getRegionParamsFromGridCoverage(GridCoverage2D gridCoverage)
Get the parameters of the region covered by the
coverage. |
static ROI |
prepareROI(Geometry roi,
AffineTransform mt2d)
Utility method for transforming a geometry ROI into the raster space, using the provided
affine transformation.
|
public static final String NORTH
public static final String SOUTH
public static final String WEST
public static final String EAST
public static final String XRES
public static final String YRES
public static final String ROWS
public static final String COLS
public static final String MINY
public static final String MINX
public static ROI prepareROI(Geometry roi,
AffineTransform mt2d)
throws ProcessException
roi - a Geometry in model space.mt2d - an AffineTransform that maps from raster to model space. This is already
referred to the pixel corner.ROI suitable for using with JAI.ProcessException - in case there are problems with ivnerting the provided AffineTransform. Very unlikely to happen.public static SimpleFeatureType createFeatureType(GridCoverage2D gc2d, Class<? extends Geometry> geometryClass)
SimpleFeatureType that exposes a coverage as a collections of feature
points, mapping the centre of each pixel as a point plus all the bands as attributes.
The FID is the long that combines x+y*width.
gc2d - the GridCoverage2D to wrap.geometryClass - the class for the geometry.SimpleFeatureType or null in case we are unable to wrap the
coveragepublic static RangeLookupTable getRangeLookupTable(List<Range> classificationRanges, Number noDataValue)
public static RangeLookupTable getRangeLookupTable(List<Range> classificationRanges, Number noDataValue, Class clazz)
public static RangeLookupTable getRangeLookupTable(List<Range> classificationRanges, int[] outputPixelValues, Number noDataValue)
public static RangeLookupTable getRangeLookupTable(List<Range> classificationRanges, int[] outputPixelValues, Number noDataValue, Class<? extends Number> clazz)
public static RangeLookupTable getRangeLookupTableJAIEXT(List<Range> classificationRanges, int[] outputPixelValues, Number noDataValue, int transferType)
public static HashMap<String,Double> getRegionParamsFromGridCoverage(GridCoverage2D gridCoverage)
coverage.Copyright © 1996–2019 Geotools. All rights reserved.