Package inra.ijpb.morphology.strel
Class AbstractSeparableStrel
java.lang.Object
inra.ijpb.algo.AlgoStub
inra.ijpb.morphology.strel.AbstractStrel3D
inra.ijpb.morphology.strel.AbstractStrel
inra.ijpb.morphology.strel.AbstractSeparableStrel
- All Implemented Interfaces:
Algo
,AlgoListener
,Strel
,SeparableStrel
,Strel3D
- Direct Known Subclasses:
DiamondStrel
,OctagonStrel
,SquareStrel
public abstract class AbstractSeparableStrel extends AbstractStrel implements SeparableStrel, AlgoListener
Implementation stub for separable Structuring elements.
- Author:
- David Legland
-
Nested Class Summary
Nested classes/interfaces inherited from interface inra.ijpb.morphology.Strel
Strel.Shape
Nested classes/interfaces inherited from interface inra.ijpb.morphology.Strel3D
Strel3D.Shape
-
Field Summary
Fields inherited from interface inra.ijpb.morphology.Strel
BACKGROUND, FOREGROUND
Fields inherited from interface inra.ijpb.morphology.Strel3D
BACKGROUND, FOREGROUND
-
Constructor Summary
Constructors Constructor Description AbstractSeparableStrel()
-
Method Summary
Modifier and Type Method Description void
algoProgressChanged(AlgoEvent evt)
Propagates the event by changing the source.void
algoStatusChanged(AlgoEvent evt)
Propagates the event by changing the source.ij.process.ImageProcessor
closing(ij.process.ImageProcessor image)
Performs a morphological closing on the input image, by applying first a dilation, then an erosion with the reversed structuring element.ij.process.ImageProcessor
dilation(ij.process.ImageProcessor image)
Implements a default algorithm for dilation, that consists in iterating over the neighbors of each pixel to compute the maximum value.ij.process.ImageProcessor
erosion(ij.process.ImageProcessor image)
Implements a default algorithm for erosion, that consists in iterating over the neighbors of each pixel to compute the minimum value.ij.process.ImageProcessor
opening(ij.process.ImageProcessor image)
Performs a morphological opening on the input image, by applying first an erosion, then a dilation with the reversed structuring element.Methods inherited from class inra.ijpb.morphology.strel.AbstractStrel
addBorder, closing, cropBorder, dilation, erosion, getChannelName, getMask3D, getShifts3D, opening, setChannelName
Methods inherited from class inra.ijpb.morphology.strel.AbstractStrel3D
addBorder, cropBorder, showProgress, showProgress
Methods inherited from class inra.ijpb.algo.AlgoStub
addAlgoListener, removeAlgoListener
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface inra.ijpb.algo.Algo
addAlgoListener, removeAlgoListener
Methods inherited from interface inra.ijpb.morphology.strel.SeparableStrel
decompose, reverse
Methods inherited from interface inra.ijpb.morphology.Strel
getChannelName, getMask, getOffset, getShifts, getSize, setChannelName
Methods inherited from interface inra.ijpb.morphology.Strel3D
closing, dilation, erosion, getMask3D, getShifts3D, opening, showProgress, showProgress
-
Constructor Details
-
AbstractSeparableStrel
public AbstractSeparableStrel()
-
-
Method Details
-
dilation
public ij.process.ImageProcessor dilation(ij.process.ImageProcessor image)Description copied from class:AbstractStrel
Implements a default algorithm for dilation, that consists in iterating over the neighbors of each pixel to compute the maximum value. The neighbors are obtained via thegetShifts()
method.- Specified by:
dilation
in interfaceStrel
- Overrides:
dilation
in classAbstractStrel
- Parameters:
image
- the input image- Returns:
- the result of dilation with this structuring element
- See Also:
Strel.getShifts()
,AbstractStrel.erosion(ImageProcessor)
-
erosion
public ij.process.ImageProcessor erosion(ij.process.ImageProcessor image)Description copied from class:AbstractStrel
Implements a default algorithm for erosion, that consists in iterating over the neighbors of each pixel to compute the minimum value. The neighbors are obtained via thegetShifts()
method.- Specified by:
erosion
in interfaceStrel
- Overrides:
erosion
in classAbstractStrel
- Parameters:
image
- the input image- Returns:
- the result of erosion with this structuring element
- See Also:
Strel.getShifts()
,AbstractStrel.dilation(ImageProcessor)
-
closing
public ij.process.ImageProcessor closing(ij.process.ImageProcessor image)Description copied from class:AbstractStrel
Performs a morphological closing on the input image, by applying first a dilation, then an erosion with the reversed structuring element.- Specified by:
closing
in interfaceStrel
- Overrides:
closing
in classAbstractStrel
- Parameters:
image
- the input image- Returns:
- the result of closing with this structuring element
- See Also:
AbstractStrel.dilation(ij.process.ImageProcessor)
,AbstractStrel.erosion(ij.process.ImageProcessor)
,AbstractStrel.opening(ij.process.ImageProcessor)
,Strel3D.reverse()
-
opening
public ij.process.ImageProcessor opening(ij.process.ImageProcessor image)Description copied from class:AbstractStrel
Performs a morphological opening on the input image, by applying first an erosion, then a dilation with the reversed structuring element.- Specified by:
opening
in interfaceStrel
- Overrides:
opening
in classAbstractStrel
- Parameters:
image
- the input image- Returns:
- the result of opening with this structuring element
- See Also:
AbstractStrel.dilation(ij.process.ImageProcessor)
,AbstractStrel.erosion(ij.process.ImageProcessor)
,AbstractStrel.closing(ij.process.ImageProcessor)
,Strel3D.reverse()
-
algoProgressChanged
Propagates the event by changing the source.- Specified by:
algoProgressChanged
in interfaceAlgoListener
- Parameters:
evt
- the AlgoEvent instance containing info about the algorithm.
-
algoStatusChanged
Propagates the event by changing the source.- Specified by:
algoStatusChanged
in interfaceAlgoListener
- Parameters:
evt
- the AlgoEvent instance containing info about the algorithm.
-