All Implemented Interfaces:
Serializable, Operation

public class Extrema extends BaseStatisticsOperationJAI
This operation simply wraps JAI Extrema operations described by ExtremaDescriptor inside a GeoTools operation in order to make it spatial-aware.

For the moment this is a very simple wrap. Plans on the 2.4 and successive versions of this operation are to add the ability to use spatial ROIs and to specific Spatial subsampling. As of now, ROI has to be a Java2D Shape subclass and the parameters to control x and y subsamplings got to be Integer, which means pixel-aware.

For more information on how the underlying JAI operators works you can have a look here: ExtremaDescriptor

How to use this operation Here is a very simple example on how to use this operation in order to the minimum and maximum of the source coverage. final OperationJAI op=new OperationJAI("Extrema"); ParameterValueGroup params = op.getParameters(); params.parameter("Source").setValue(coverage); coverage=(GridCoverage2D) op.doOperation(params,null); System.out.println(((double[])coverage.getProperty("minimum"))[0]); System.out.println(((double[])coverage.getProperty("minimum"))[1]); System.out.println(((double[])coverage.getProperty("minimum"))[2]); System.out.println(((double[])coverage.getProperty("maximum"))[0]); System.out.println(((double[])coverage.getProperty("maximum"))[1]); System.out.println(((double[])coverage.getProperty("maximum"))[2]);

Since:
2.4
Author:
Simone Giannecchini
See Also: