C# 클래스 AForge.Imaging.Filters.ConnectedComponentsLabeling

Connected components labeling.

The filter performs labeling of objects in the source image. It colors each separate object using different color. The image processing filter treats all none black pixels as objects' pixels and all black pixel as background.

The filter accepts 8 bpp grayscale images and 24/32 bpp color images and produces 24 bpp RGB image.

Sample usage:

// create filter ConnectedComponentsLabeling filter = new ConnectedComponentsLabeling( ); // apply the filter Bitmap newImage = filter.Apply( image ); // check objects count int objectCount = filter.ObjectCount;

Initial image:

Result image:

상속: BaseFilter
파일 보기 프로젝트 열기: holisticware-admin/MonoVersal.AForgeNET 1 사용 예제들

공개 메소드들

메소드 설명
ConnectedComponentsLabeling ( ) : System

Initializes a new instance of the ConnectedComponentsLabeling class.

보호된 메소드들

메소드 설명
ProcessFilter ( UnmanagedImage sourceData, UnmanagedImage destinationData ) : void

Process the filter on the specified image.

메소드 상세

ConnectedComponentsLabeling() 공개 메소드

Initializes a new instance of the ConnectedComponentsLabeling class.
public ConnectedComponentsLabeling ( ) : System
리턴 System

ProcessFilter() 보호된 메소드

Process the filter on the specified image.
protected ProcessFilter ( UnmanagedImage sourceData, UnmanagedImage destinationData ) : void
sourceData UnmanagedImage Source image data.
destinationData UnmanagedImage Destination image data.
리턴 void