IMAGE - the underlying image typepublic class SimplePyramid<IMAGE extends Image<?,IMAGE> & SinglebandImageProcessor.Processable<Float,FImage,IMAGE>> extends Object implements ImageAnalyser<IMAGE>, ImageProcessor<IMAGE>, Iterable<IMAGE>
ImageProcessor, the last level of the
pyramid will be assigned to the input image.
SimplePyramids also allow you to specify a processor that is applied
between levels. For example, a Gaussian blur could be applied to make a
Gaussian pyramid.
SimplePyramids are @link{Iterable}, so you can iterate over the levels.| Modifier and Type | Field and Description |
|---|---|
IMAGE[] |
pyramid
The images forming the pyramid
|
| Constructor and Description |
|---|
SimplePyramid(float power)
Construct a pyramid with the given scale factor.
|
SimplePyramid(float power,
int nlevels)
Construct a pyramid with the given scale factor and number of levels.
|
SimplePyramid(float power,
int nlevels,
Processor<IMAGE> processor)
Construct a pyramid with the given scale factor and number of levels.
|
SimplePyramid(float power,
Processor<IMAGE> processor)
Construct a pyramid with the given scale factor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
analyseImage(IMAGE image)
Analyse an image.
|
protected int |
computeLevels(int size)
compute the number of levels such that the minimum size is at least 8.
|
static <T extends Image<?,T> & SinglebandImageProcessor.Processable<Float,FImage,T>> |
createGaussianPyramid(T image,
float sigma,
int nLevels)
Convenience method to create a gaussian pyramid from an image.
|
Iterator<IMAGE> |
iterator() |
void |
processImage(IMAGE image)
Process an image.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitforEach, spliteratorpublic SimplePyramid(float power)
power - scale factor between levelspublic SimplePyramid(float power, int nlevels)
power - scale factor between levelsnlevels - number of levelspublic SimplePyramid(float power, Processor<IMAGE> processor)
power - scale factor between levelsprocessor - a processor to apply before subsamplingpublic SimplePyramid(float power, int nlevels, Processor<IMAGE> processor)
power - scale factor between levelsnlevels - number of levelsprocessor - a processor to apply before subsamplingprotected int computeLevels(int size)
size - sizepublic void analyseImage(IMAGE image)
ImageAnalyseranalyseImage in interface ImageAnalyser<IMAGE extends Image<?,IMAGE> & SinglebandImageProcessor.Processable<Float,FImage,IMAGE>>image - The image to process in place.public void processImage(IMAGE image)
ImageProcessorImage.internalAssign(Image).processImage in interface ImageProcessor<IMAGE extends Image<?,IMAGE> & SinglebandImageProcessor.Processable<Float,FImage,IMAGE>>image - The image to process in place.public static <T extends Image<?,T> & SinglebandImageProcessor.Processable<Float,FImage,T>> SimplePyramid<T> createGaussianPyramid(T image, float sigma, int nLevels)
T - The type of imageimage - the imagesigma - the amount of blurringnLevels - the number of levels