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

Threshold binarization with error carry.

The filter is similar to Threshold filter in the way, that it also uses threshold value for image binarization. Unlike regular threshold filter, this filter uses cumulative pixel value in comparing with threshold value. If cumulative pixel value is below threshold value, then image pixel becomes black. If cumulative pixel value is equal or higher than threshold value, then image pixel becomes white and cumulative pixel value is decreased by 255. In the beginning of each image line the cumulative value is reset to 0.

The filter accepts 8 bpp grayscale images for processing.

Sample usage:

// create filter Threshold filter = new Threshold( 100 ); // apply the filter filter.ApplyInPlace( image );

Initial image:

Result image:

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

공개 메소드들

메소드 설명
ThresholdWithCarry ( ) : System

Initializes a new instance of the ThresholdWithCarry class.

ThresholdWithCarry ( byte threshold ) : System

Initializes a new instance of the ThresholdWithCarry class.

보호된 메소드들

메소드 설명
ProcessFilter ( UnmanagedImage image, Rectangle rect ) : void

Process the filter on the specified image.

메소드 상세

ProcessFilter() 보호된 메소드

Process the filter on the specified image.
protected ProcessFilter ( UnmanagedImage image, Rectangle rect ) : void
image UnmanagedImage Source image data.
rect System.Drawing.Rectangle Image rectangle for processing by the filter.
리턴 void

ThresholdWithCarry() 공개 메소드

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

ThresholdWithCarry() 공개 메소드

Initializes a new instance of the ThresholdWithCarry class.
public ThresholdWithCarry ( byte threshold ) : System
threshold byte Threshold value.
리턴 System