C# 클래스 ZXing.QrCode.Internal.AlignmentPatternFinder

This class attempts to find alignment patterns in a QR Code. Alignment patterns look like finder patterns but are smaller and appear at regular intervals throughout the image.

At the moment this only looks for the bottom-right alignment pattern.

This is mostly a simplified copy of {@link FinderPatternFinder}. It is copied, pasted and stripped down here for maximum performance but does unfortunately duplicate some code.

This class is thread-safe but not reentrant. Each thread must allocate its own object.

파일 보기 프로젝트 열기: Redth/ZXing.Net.Mobile 1 사용 예제들

비공개 메소드들

메소드 설명
AlignmentPatternFinder ( BitMatrix image, int startX, int startY, int width, int height, float moduleSize, ResultPointCallback resultPointCallback ) : System

Creates a finder that will look in a portion of the whole image.

centerFromEnd ( int stateCount, int end ) : float?

Given a count of black/white/black pixels just seen and an end position, figures the location of the center of this black/white/black run.

crossCheckVertical ( int startI, int centerJ, int maxCount, int originalStateCountTotal ) : float?

After a horizontal scan finds a potential alignment pattern, this method "cross-checks" by scanning down vertically through the center of the possible alignment pattern to see if the same proportion is detected.

find ( ) : ZXing.QrCode.Internal.AlignmentPattern

This method attempts to find the bottom-right alignment pattern in the image. It is a bit messy since it's pretty performance-critical and so is written to be fast foremost.

foundPatternCross ( int stateCount ) : bool
handlePossibleCenter ( int stateCount, int i, int j ) : ZXing.QrCode.Internal.AlignmentPattern

This is called when a horizontal scan finds a possible alignment pattern. It will cross check with a vertical scan, and if successful, will see if this pattern had been found on a previous horizontal scan. If so, we consider it confirmed and conclude we have found the alignment pattern.