|
||||||||||
| PREV PACKAGE NEXT PACKAGE | FRAMES NO FRAMES | |||||||||
See:
Description
| Class Summary | |
|---|---|
| Absolute | Computes the mathematical absolute value of each sample value. |
| AddConst | Adds constants (one for each band) to every sample values of the source coverage. |
| Convolve | Computes each output sample by multiplying elements of a kernel with the samples surrounding a particular source sample. |
| DivideByConst | Divides every sample values of the source coverage by constants (one for each band). |
| Exp | Takes the exponential of the sample values of a coverage. |
| GradientMagnitude | Edge detector which computes the magnitude of the image gradient vector in two orthogonal directions. |
| Interpolate | Specifies the interpolation type to be used to interpolate values for points which fall between grid cells. |
| Invert | Inverts the sample values of a coverage. |
| Log | Takes the natural logarithm of the sample values of a coverage. |
| MaxFilter | For each position of the mask, replaces the center pixel by the maximum of the pixel values covered by the mask. |
| MedianFilter | For each position of the mask, replaces the center pixel by the median of the pixel values covered by the mask. |
| MinFilter | For each position of the mask, replaces the center pixel by the minimum of the pixel values covered by the mask. |
| MultiplyConst | Multiplies every sample values of the source coverage by constants (one for each band). |
| NodataFilter | Replaces NaN values by the weighted average of neighbors values. |
| Recolor | Replaces the colors of a GridCoverage2D. |
| Resample | Resample a grid coverage using a different grid geometry. |
| Rescale | Maps the sample values of a coverage from one range to another range. |
| SelectSampleDimension | Chooses N sample dimensions from a grid coverage and copies their sample data to the destination grid coverage in the order specified. |
| SubtractConst | Subtracts constants (one for each band) from every sample values of the source coverage. |
| SubtractFromConst | Subtracts every sample values of the source coverage from constants (one for each band). |
Implementations of operations. This package is useful for documentation purpose since class names match exactly operation names, and the javadoc for each class provides a table of valid arguments. But the classes provided there should not be used directly. There is no need to instantiate them, since it is already done by the default coverage processor which manage them.
If the operation to apply is know at compile time, then the easiest way to use this package
is to use the Operations convenience class. For
example a grid coverage can be resampled
to a different coordinate
reference system using the following code:
If the operation to apply is unknown at compile time (for example because it is selected at runtime by the user in some widget), or if the operation is not listed in theCoverage reprojected = Operations.DEFAULT.resample(myCoverage, newCRS);
Operations convenience class, then the generic way is to invoke the
doOperation method
on the default
processor instance. Available operations are listed in this package, but the tables below
summarize the main ones.
Computes each output sample by multiplying elements of a kernel with the samples surrounding a particular source sample.
Name: "Convolve"
JAI operator: "Convolve"
Parameters:
| Name | Class | Default value | Minimum value | Maximum value |
|---|---|---|---|---|
"Source" |
GridCoverage2D |
N/A | N/A | N/A |
"kernel" |
KernelJAI |
N/A | N/A | N/A |
Perform a laplacian filter operation on a grid coverage. This is a high pass filter which
highlights the edges having positive and negative brightness slopes. This filter mulitples the
co-efficients in the tabe below with the corresponding grid data value in the kernel window.
The new grid value will be calculated as the sum of (grid value * co-efficient)
for each kernel cell divised by 9.
| 0 | -1 | 0 |
| -1 | 4 | -1 |
| 0 | -1 | 0 |
Name: "LaplaceType1Filter"
JAI operator: "Convolve"
Parameters:
| Name | Class | Default value | Minimum value | Maximum value |
|---|---|---|---|---|
"Source" |
GridCoverage2D |
N/A | N/A | N/A |
Perform a laplacian filter operation on a grid coverage. This is a high pass filter which
highlights the edges having positive and negative brightness slopes. This filter mulyiplies
the co-efficients in the tabe below with the corresponding grid data value in the kernel window.
The new grid value will be calculated as the sum of (grid value * co-efficient)
for each kernel cell divised by 9.
| -1 | -1 | -1 |
| -1 | 8 | -1 |
| -1 | -1 | -1 |
Name: "LaplaceType1Filter"
JAI operator: "Convolve"
Parameters:
| Name | Class | Default value | Minimum value | Maximum value |
|---|---|---|---|---|
"Source" |
GridCoverage2D |
N/A | N/A | N/A |
Non-linear filter which is useful for removing isolated lines or pixels while preserving the overall appearance of an image. The filter is implemented by moving a mask over the image. For each position of the mask, the center pixel is replaced by the max of the pixel values covered by the mask. There are several shapes possible for the mask, which are enumerated in the JAI documentation.
Name: "MaxFilter"
JAI operator: "MaxFilter"
Parameters:
| Name | Class | Default value | Minimum value | Maximum value |
|---|---|---|---|---|
"Source" |
GridCoverage2D |
N/A | N/A | N/A |
"Xsize" |
Integer |
3 | 1 | N/A |
"Ysize" |
Integer |
3 | 1 | N/A |
"maskShape" |
MaxFilterShape |
MaxFilterDescriptor.MAX_MASK_SQUARE |
N/A | N/A |
Note: In current implementation, Xsize and Ysize
must have the same value (i.e. rectangular shapes are not supported).
Non-linear filter which is useful for removing isolated lines or pixels while preserving the overall appearance of an image. The filter is implemented by moving a mask over the image. For each position of the mask, the center pixel is replaced by the median of the pixel values covered by the mask. This filter results in a smoothing of the image values. There are several shapes possible for the mask, which are enumerated in the JAI documentation.
Name: "MedianFilter"
JAI operator: "MedianFilter"
Parameters:
| Name | Class | Default value | Minimum value | Maximum value |
|---|---|---|---|---|
"Source" |
GridCoverage2D |
N/A | N/A | N/A |
"Xsize" |
Integer |
3 | 1 | N/A |
"Ysize" |
Integer |
3 | 1 | N/A |
"maskShape" |
MedianFilterShape |
MedianFilterDescriptor.MEDIAN_MASK_SQUARE |
N/A | N/A |
Note: In current implementation, Xsize and Ysize must
have the same value (i.e. rectangular shapes are not supported).
Non-linear filter which is useful for removing isolated lines or pixels while preserving the overall appearance of an image. The filter is implemented by moving a mask over the image. For each position of the mask, the center pixel is replaced by the min of the pixel values covered by the mask. There are several shapes possible for the mask, which are enumerated in the JAI documentation.
Name: "MinFilter"
JAI operator: "MinFilter"
Parameters:
| Name | Class | Default value | Minimum value | Maximum value |
|---|---|---|---|---|
"Source" |
GridCoverage2D |
N/A | N/A | N/A |
"Xsize" |
Integer |
3 | 1 | N/A |
"Ysize" |
Integer |
3 | 1 | N/A |
"maskShape" |
MinFilterShape |
MinFilterDescriptor.MIN_MASK_SQUARE |
N/A | N/A |
Note: In current implementation, Xsize and Ysize must
have the same value (i.e. rectangular shapes are not supported).
Changes the colors associated to arbitrary categories
in arbitrary bands. The ColorMaps arguments must be an array of Maps
with a minimal length of 1. The Map in array element 0 is used
for band 0; the Map in array element 1 is used for band 1, etc.
If there is more bands than array elements in ColorMaps, then
the last Map is reused for all remaining bands.
For each Map in ColorMaps, the keys are category names as
String and the values are colors as an array of type
Color[]. All categories with a name matching a key in
the Map will be recolored with
the associated colors. All categories with no corresponding entries in the Map
will be left unchanged. The null key is a special value meaning "any quantitative
category". For example in order to repaint forest in green, river in blue and lets other
categories unchanged, one can write:
Map map = new HashMap();
map.put("Forest", new Color[]{Color.GREEN});
map.put("River", new Color[]{Color.BLUE });
Map[] colorMaps = new Map[] {
map // Use for all bands
}
Name: "Recolor"
JAI operator: N/A
Parameters:
| Name | Class | Default value | Minimum value | Maximum value |
|---|---|---|---|---|
"Source" |
GridCoverage2D |
N/A | N/A | N/A |
"ColorMaps" |
Map[] |
A gray scale | N/A | N/A |
A gray scale threshold classifies the grid coverage values into a boolean value. The sample dimensions will be modified into a boolean value and the dimension type of the source sample dimension will be represented as 1 bit.
Name: "Threshold"
JAI operator: "Binarize"
Parameters:
| Name | Class | Default value | Minimum value | Maximum value |
|---|---|---|---|---|
"Source" |
GridCoverage2D |
N/A | N/A | N/A |
"threshold" |
double[] |
N/A | N/A | N/A |
| coverage/geotk-coverage (download) |
|
||||||||||
| PREV PACKAGE NEXT PACKAGE | FRAMES NO FRAMES | |||||||||