mirror of
https://github.com/starovoid/rxing.git
synced 2026-07-26 04:12:34 +00:00
remove impl ResultPoint for FinderPattern & AlignmentPattern
This commit is contained in:
@@ -20,7 +20,6 @@ use crate::{
|
||||
common::{BitMatrix, Result},
|
||||
qrcode::detector::{FinderPattern, FinderPatternFinder, FinderPatternInfo},
|
||||
result_point_utils, DecodeHintType, DecodingHintDictionary, Exceptions, Point, PointCallback,
|
||||
ResultPoint,
|
||||
};
|
||||
|
||||
// max. legal count of modules per QR code edge (177)
|
||||
@@ -175,18 +174,10 @@ impl<'a> MultiFinderPatternFinder<'_> {
|
||||
|
||||
// Calculate the distances: a = topleft-bottomleft, b=topleft-topright, c = diagonal
|
||||
let info = FinderPatternInfo::new(test);
|
||||
let dA = Point::distance(
|
||||
info.getTopLeft().to_rxing_result_point(),
|
||||
info.getBottomLeft().to_rxing_result_point(),
|
||||
);
|
||||
let dC = Point::distance(
|
||||
info.getTopRight().to_rxing_result_point(),
|
||||
info.getBottomLeft().to_rxing_result_point(),
|
||||
);
|
||||
let dB = Point::distance(
|
||||
info.getTopLeft().to_rxing_result_point(),
|
||||
info.getTopRight().to_rxing_result_point(),
|
||||
);
|
||||
let dA = Point::distance(info.getTopLeft().into(), info.getBottomLeft().into());
|
||||
let dC =
|
||||
Point::distance(info.getTopRight().into(), info.getBottomLeft().into());
|
||||
let dB = Point::distance(info.getTopLeft().into(), info.getTopRight().into());
|
||||
|
||||
// Check the sizes
|
||||
let estimatedModuleCount = (dA + dB) / (p1.getEstimatedModuleSize() * 2.0);
|
||||
|
||||
Reference in New Issue
Block a user