/// Encapsulates logic that can detect a QR Code in an image, even if the QR Code
/// is rotated or skewed, or partially obscured.
///
TDetector = class
private
FImage: TBitMatrix;
FResultPointCallback: TResultPointCallback;
function calculateModuleSizeOneWay(pattern: IResultpoint;
otherPattern: IResultpoint): Single;
class function computeDimension(topLeft: IResultpoint;
topRight: IResultpoint; bottomLeft: IResultpoint; moduleSize: Single;
var dimension: Integer): boolean; static;
class function createTransform(const topLeft, topRight, bottomLeft,
AlignmentPattern: IResultpoint; const dimension: Integer)
: TPerspectiveTransform; static;
class function sampleGrid(image: TBitMatrix;
transform: TPerspectiveTransform; dimension: Integer): TBitMatrix; static;
function sizeOfBlackWhiteBlackRun(fromX: Integer; fromY: Integer;
toX: Integer; toY: Integer): Single;
function sizeOfBlackWhiteBlackRunBothWays(fromX: Integer; fromY: Integer;
toX: Integer; toY: Integer): Single;
protected
function calculateModuleSize(const topLeft, topRight,
bottomLeft: IResultPoint): Single; virtual;
function findAlignmentInRegion(const overallEstModuleSize: Single;
const estAlignmentX, estAlignmentY: Integer;
const allowanceFactor: Single): IAlignmentPattern;
///