swap point_f and point functions

This commit is contained in:
Henry Schimke
2023-05-04 14:50:32 -05:00
parent 80f06ecb3c
commit 3fc068f49b
38 changed files with 210 additions and 217 deletions

View File

@@ -16,7 +16,7 @@
use crate::{
common::{BitMatrix, Result},
point, Binarizer, BinaryBitmap, DecodingHintDictionary, Exceptions, Point,
point_f, Binarizer, BinaryBitmap, DecodingHintDictionary, Exceptions, Point,
};
use std::borrow::Cow;
@@ -244,8 +244,8 @@ fn findRowsWithPattern(
break;
}
}
result[0] = Some(point(loc_store.as_ref()?[0] as f32, startRow as f32));
result[1] = Some(point(loc_store.as_ref()?[1] as f32, startRow as f32));
result[0] = Some(point_f(loc_store.as_ref()?[0] as f32, startRow as f32));
result[1] = Some(point_f(loc_store.as_ref()?[1] as f32, startRow as f32));
found = true;
break;
}
@@ -290,8 +290,8 @@ fn findRowsWithPattern(
stopRow += 1;
}
stopRow -= skippedRowCount + 1;
result[2] = Some(point(previousRowLoc[0] as f32, stopRow as f32));
result[3] = Some(point(previousRowLoc[1] as f32, stopRow as f32));
result[2] = Some(point_f(previousRowLoc[0] as f32, stopRow as f32));
result[3] = Some(point_f(previousRowLoc[1] as f32, stopRow as f32));
}
if stopRow - startRow < BARCODE_MIN_HEIGHT {
result.fill(None);