ErosionDisk2d
Performs a two-dimensional erosion using a structuring element matching with a disk.
Access to parameter description
For an introduction:
See also
Access to parameter description
For an introduction:
- section Mathematical Morphology
- section Erosion
See also
Function Syntax
This function returns outputImage.
// Function prototype
std::shared_ptr< iolink::ImageView > erosionDisk2d( std::shared_ptr< iolink::ImageView > inputImage, uint32_t kernelRadius, ErosionDisk2d::Precision precision, std::shared_ptr< iolink::ImageView > outputImage = NULL );
Class Syntax
Parameters
Parameter Name | Description | Type | Supported Values | Default Value | |||||
---|---|---|---|---|---|---|---|---|---|
![]() |
inputImage |
The input image. The image type can be integer or float. | Image | Binary, Label, Grayscale or Multispectral | nullptr | ||||
![]() |
kernelRadius |
The length of the disk radius in pixels. | UInt32 | >=1 | 3 | ||||
![]() |
precision |
The precision of the computation method.
|
Enumeration | FASTER | |||||
![]() |
outputImage |
The output image. Its dimensions and type are forced to the same values as the input image. | Image | nullptr |
Object Examples
std::shared_ptr< iolink::ImageView > polystyrene = ioformat::readImage( std::string( IMAGEDEVDATA_IMAGES_FOLDER ) + "polystyrene.tif" ); ErosionDisk2d erosionDisk2dAlgo; erosionDisk2dAlgo.setInputImage( polystyrene ); erosionDisk2dAlgo.setKernelRadius( 3 ); erosionDisk2dAlgo.setPrecision( ErosionDisk2d::Precision::FASTER ); erosionDisk2dAlgo.execute(); std::cout << "outputImage:" << erosionDisk2dAlgo.outputImage()->toString();
Function Examples
std::shared_ptr< iolink::ImageView > polystyrene = ioformat::readImage( std::string( IMAGEDEVDATA_IMAGES_FOLDER ) + "polystyrene.tif" ); auto result = erosionDisk2d( polystyrene, 3, ErosionDisk2d::Precision::FASTER ); std::cout << "outputImage:" << result->toString();