ITK
6.0.0
Insight Toolkit
|
#include <itkMorphologyImageFilter.h>
Base class for the morphological operations such as erosion and dilation.
This class provides the infrastructure to support most morphological operations. Subclasses of MorphologyImageFilter implement specific "binary" and "grayscale" operations. The "binary" subclasses can operate on gray level data, where a specified a pixel value is consider the "foreground" and every other pixel value is considered the background. This is useful for operating on segment masks where all pixels assigned to segment #1 have value 1, all pixels assigned to segment #2 have value 2, etc. Here, a given segment can be dilated (expanded) while treating all other segment identifiers are background.
The "kernel" specified represents a morphology structuring element. The structuring element is a small Neighborhood with values indicating an element is "on" (value > 0) or "off" (value <=0). Morphological operations are defined by placing the structuring element over a pixel, and calculating a nonlinear function (min, max) over the pixels of the image that are under pixels in the structuring element that are "on". The result of this calculation is the value of the pixel in the output image. Under most circumstances, the "center pixel" of the structuring element – or structuring element pixel over the input pixel under consideration – is prescribed to be "on". This is not a strict requirement but the subclasses of this filter are not guaranteed to produce the correct result if the "center pixel" is not part of the structuring element.
Subclasses of this class can define their own operations by simply providing their own Evaluate() protected member function.
Definition at line 72 of file itkMorphologyImageFilter.h.
Public Types | |
using | ConstPointer = SmartPointer< const Self > |
using | DefaultBoundaryConditionType = ConstantBoundaryCondition< InputImageType > |
using | ImageBoundaryConditionConstPointerType = const ImageBoundaryCondition< InputImageType > * |
using | ImageBoundaryConditionPointerType = ImageBoundaryCondition< InputImageType > * |
using | IndexType = typename TInputImage::IndexType |
using | InputImageType = TInputImage |
using | KernelIteratorType = typename KernelType::ConstIterator |
using | KernelType = TKernel |
using | NeighborhoodIteratorType = ConstNeighborhoodIterator< TInputImage > |
using | OutputImageType = TOutputImage |
using | PixelType = typename TInputImage::PixelType |
using | Pointer = SmartPointer< Self > |
using | RadiusType = typename KernelType::SizeType |
using | RegionType = typename TInputImage::RegionType |
using | Self = MorphologyImageFilter |
using | SizeType = typename TInputImage::SizeType |
using | Superclass = KernelImageFilter< TInputImage, TOutputImage, TKernel > |
Public Types inherited from itk::KernelImageFilter< TInputImage, TOutputImage, TKernel > | |
using | ConstPointer = SmartPointer< const Self > |
using | FlatKernelType = FlatStructuringElement<(Self::ImageDimension)> |
using | IndexType = typename TInputImage::IndexType |
using | InputImageType = TInputImage |
using | InputPixelType = typename TInputImage::PixelType |
using | KernelType = TKernel |
using | OffsetType = typename TInputImage::OffsetType |
using | OutputImageType = TOutputImage |
using | OutputPixelType = typename TOutputImage::PixelType |
using | Pointer = SmartPointer< Self > |
using | RadiusType = typename TInputImage::SizeType |
using | RegionType = typename TInputImage::RegionType |
using | Self = KernelImageFilter |
using | SizeType = typename TInputImage::SizeType |
using | Superclass = BoxImageFilter< TInputImage, TOutputImage > |
Public Types inherited from itk::BoxImageFilter< TInputImage, TOutputImage > | |
using | ConstPointer = SmartPointer< const Self > |
using | IndexType = typename TInputImage::IndexType |
using | InputImageType = TInputImage |
using | InputPixelType = typename TInputImage::PixelType |
using | OffsetType = typename TInputImage::OffsetType |
using | OutputImageType = TOutputImage |
using | OutputPixelType = typename TOutputImage::PixelType |
using | Pointer = SmartPointer< Self > |
using | RadiusType = typename TInputImage::SizeType |
using | RadiusValueType = typename TInputImage::SizeValueType |
using | RegionType = typename TInputImage::RegionType |
using | Self = BoxImageFilter |
using | SizeType = typename TInputImage::SizeType |
using | Superclass = ImageToImageFilter< TInputImage, TOutputImage > |
Public Types inherited from itk::ImageToImageFilter< TInputImage, TOutputImage > | |
using | ConstPointer = SmartPointer< const Self > |
using | InputImageConstPointer = typename InputImageType::ConstPointer |
using | InputImagePixelType = typename InputImageType::PixelType |
using | InputImagePointer = typename InputImageType::Pointer |
using | InputImageRegionType = typename InputImageType::RegionType |
using | InputImageType = TInputImage |
using | Pointer = SmartPointer< Self > |
using | Self = ImageToImageFilter |
using | Superclass = ImageSource< TOutputImage > |
Public Types inherited from itk::ImageSource< TOutputImage > | |
using | ConstPointer = SmartPointer< const Self > |
using | DataObjectIdentifierType = Superclass::DataObjectIdentifierType |
using | DataObjectPointer = DataObject::Pointer |
using | DataObjectPointerArraySizeType = Superclass::DataObjectPointerArraySizeType |
using | OutputImagePixelType = typename OutputImageType::PixelType |
using | OutputImagePointer = typename OutputImageType::Pointer |
using | OutputImageRegionType = typename OutputImageType::RegionType |
using | OutputImageType = TOutputImage |
using | Pointer = SmartPointer< Self > |
using | Self = ImageSource |
using | Superclass = ProcessObject |
Public Types inherited from itk::ProcessObject | |
using | ConstPointer = SmartPointer< const Self > |
using | DataObjectIdentifierType = DataObject::DataObjectIdentifierType |
using | DataObjectPointer = DataObject::Pointer |
using | DataObjectPointerArray = std::vector< DataObjectPointer > |
using | DataObjectPointerArraySizeType = DataObjectPointerArray::size_type |
using | MultiThreaderType = MultiThreaderBase |
using | NameArray = std::vector< DataObjectIdentifierType > |
using | Pointer = SmartPointer< Self > |
using | Self = ProcessObject |
using | Superclass = Object |
Public Types inherited from itk::Object | |
using | ConstPointer = SmartPointer< const Self > |
using | Pointer = SmartPointer< Self > |
using | Self = Object |
using | Superclass = LightObject |
Public Types inherited from itk::LightObject | |
using | ConstPointer = SmartPointer< const Self > |
using | Pointer = SmartPointer< Self > |
using | Self = LightObject |
Static Public Attributes | |
static constexpr unsigned int | ImageDimension = TInputImage::ImageDimension |
Static Public Attributes inherited from itk::KernelImageFilter< TInputImage, TOutputImage, TKernel > | |
static constexpr unsigned int | ImageDimension = TInputImage::ImageDimension |
Static Public Attributes inherited from itk::BoxImageFilter< TInputImage, TOutputImage > | |
static constexpr unsigned int | ImageDimension = TInputImage::ImageDimension |
Static Public Attributes inherited from itk::ImageToImageFilter< TInputImage, TOutputImage > | |
static constexpr unsigned int | InputImageDimension = TInputImage::ImageDimension |
static constexpr unsigned int | OutputImageDimension = TOutputImage::ImageDimension |
Static Public Attributes inherited from itk::ImageSource< TOutputImage > | |
static constexpr unsigned int | OutputImageDimension = TOutputImage::ImageDimension |
Private Attributes | |
ImageBoundaryConditionPointerType | m_BoundaryCondition {} |
DefaultBoundaryConditionType | m_DefaultBoundaryCondition {} |
using itk::MorphologyImageFilter< TInputImage, TOutputImage, TKernel >::ConstPointer = SmartPointer<const Self> |
Definition at line 81 of file itkMorphologyImageFilter.h.
using itk::MorphologyImageFilter< TInputImage, TOutputImage, TKernel >::DefaultBoundaryConditionType = ConstantBoundaryCondition<InputImageType> |
Definition at line 101 of file itkMorphologyImageFilter.h.
using itk::MorphologyImageFilter< TInputImage, TOutputImage, TKernel >::ImageBoundaryConditionConstPointerType = const ImageBoundaryCondition<InputImageType> * |
Definition at line 100 of file itkMorphologyImageFilter.h.
using itk::MorphologyImageFilter< TInputImage, TOutputImage, TKernel >::ImageBoundaryConditionPointerType = ImageBoundaryCondition<InputImageType> * |
Typedef for boundary conditions.
Definition at line 99 of file itkMorphologyImageFilter.h.
using itk::MorphologyImageFilter< TInputImage, TOutputImage, TKernel >::IndexType = typename TInputImage::IndexType |
Definition at line 91 of file itkMorphologyImageFilter.h.
using itk::MorphologyImageFilter< TInputImage, TOutputImage, TKernel >::InputImageType = TInputImage |
Image related type alias.
Definition at line 87 of file itkMorphologyImageFilter.h.
using itk::MorphologyImageFilter< TInputImage, TOutputImage, TKernel >::KernelIteratorType = typename KernelType::ConstIterator |
Kernel (structuring element) iterator.
Definition at line 110 of file itkMorphologyImageFilter.h.
using itk::MorphologyImageFilter< TInputImage, TOutputImage, TKernel >::KernelType = TKernel |
Kernel type alias.
Definition at line 107 of file itkMorphologyImageFilter.h.
using itk::MorphologyImageFilter< TInputImage, TOutputImage, TKernel >::NeighborhoodIteratorType = ConstNeighborhoodIterator<TInputImage> |
Neighborhood iterator type.
Definition at line 104 of file itkMorphologyImageFilter.h.
using itk::MorphologyImageFilter< TInputImage, TOutputImage, TKernel >::OutputImageType = TOutputImage |
Definition at line 88 of file itkMorphologyImageFilter.h.
using itk::MorphologyImageFilter< TInputImage, TOutputImage, TKernel >::PixelType = typename TInputImage::PixelType |
Definition at line 92 of file itkMorphologyImageFilter.h.
using itk::MorphologyImageFilter< TInputImage, TOutputImage, TKernel >::Pointer = SmartPointer<Self> |
Definition at line 80 of file itkMorphologyImageFilter.h.
using itk::MorphologyImageFilter< TInputImage, TOutputImage, TKernel >::RadiusType = typename KernelType::SizeType |
n-dimensional Kernel radius.
Definition at line 113 of file itkMorphologyImageFilter.h.
using itk::MorphologyImageFilter< TInputImage, TOutputImage, TKernel >::RegionType = typename TInputImage::RegionType |
Definition at line 89 of file itkMorphologyImageFilter.h.
using itk::MorphologyImageFilter< TInputImage, TOutputImage, TKernel >::Self = MorphologyImageFilter |
Standard Self type alias
Definition at line 78 of file itkMorphologyImageFilter.h.
using itk::MorphologyImageFilter< TInputImage, TOutputImage, TKernel >::SizeType = typename TInputImage::SizeType |
Definition at line 90 of file itkMorphologyImageFilter.h.
using itk::MorphologyImageFilter< TInputImage, TOutputImage, TKernel >::Superclass = KernelImageFilter<TInputImage, TOutputImage, TKernel> |
Definition at line 79 of file itkMorphologyImageFilter.h.
|
protected |
|
overrideprotecteddefault |
|
overrideprotectedvirtual |
Multi-thread version of GenerateData.
Reimplemented from itk::ImageSource< TOutputImage >.
|
protectedpure virtual |
Evaluate image neighborhood with kernel to find the new value for the center pixel value.
Implemented in itk::GrayscaleFunctionDilateImageFilter< TInputImage, TOutputImage, TKernel >, itk::GrayscaleFunctionErodeImageFilter< TInputImage, TOutputImage, TKernel >, itk::BasicDilateImageFilter< TInputImage, TOutputImage, TKernel >, and itk::BasicErodeImageFilter< TInputImage, TOutputImage, TKernel >.
|
virtual |
Get the current boundary condition.
|
overridevirtual |
Reimplemented from itk::KernelImageFilter< TInputImage, TOutputImage, TKernel >.
|
inline |
Allows a user to override the internal boundary condition. Care should be be taken to ensure that the overriding boundary condition is a persistent object during the time it is referenced. The overriding condition can be of a different type than the default type as long as it is a subclass of ImageBoundaryCondition.
Definition at line 121 of file itkMorphologyImageFilter.h.
|
overrideprotectedvirtual |
Methods invoked by Print() to print information about the object including superclasses. Typically not called by the user (use Print() instead) but used in the hierarchical print process to combine the output of several classes.
Reimplemented from itk::KernelImageFilter< TInputImage, TOutputImage, TKernel >.
|
inline |
Rest the boundary condition to the default
Definition at line 128 of file itkMorphologyImageFilter.h.
|
staticconstexpr |
Image related type alias.
Definition at line 96 of file itkMorphologyImageFilter.h.
|
private |
Pointer to a persistent boundary condition object used for the image iterator.
Definition at line 157 of file itkMorphologyImageFilter.h.
|
private |
Default boundary condition
Definition at line 160 of file itkMorphologyImageFilter.h.