Closing operator from Mathematical Morphology.

Closing morphology operator equals to dilatation followed by erosion.

Applied to binary image, the filter may be used connect or fill objects. Since dilatation is used first, it may connect/fill object areas. Then erosion restores objects. But since dilatation may connect something before, erosion may not remove after that because of the formed connection.

See documentation to Erosion and Dilatation classes for more information and list of supported pixel formats.

Sample usage:

// create filter Closing filter = new Closing( ); // apply the filter filter.Apply( image );

Initial image:

Result image:

Наследование: IFilter, IInPlaceFilter, IInPlacePartialFilter, IFilterInformation
Пример #1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="BottomHat"/> class.
 /// </summary>
 ///
 /// <param name="se">Structuring element to pass to <see cref="Closing"/> operator.</param>
 ///
 public BottomHat(short[,] se) : this()
 {
     closing = new Closing(se);
 }
Пример #2
0
 private void SetFilter()
 {
     ImageType = ImageTypes.Rgb24bpp;
     Af.Closing newFilter = new Af.Closing();
     imageFilter = newFilter;
 }
Пример #3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="BottomHat"/> class.
 /// </summary>
 /// 
 /// <param name="se">Structuring element to pass to <see cref="Closing"/> operator.</param>
 /// 
 public BottomHat( short[,] se ) : this( )
 {
     closing = new Closing( se );
 }