mirror of
https://github.com/zxing/zxing.git
synced 2025-03-05 20:48:51 -08:00
Marginal improvement to datamatrix decoder
git-svn-id: https://zxing.googlecode.com/svn/trunk@937 59b500cc-1b3d-0410-9834-0bbf25fbcc57
This commit is contained in:
parent
436ee016d3
commit
793f4c7176
|
@ -147,6 +147,10 @@ public final class Detector {
|
|||
|
||||
int dimension = Math.min(transitionsBetween(topLeft, topRight).getTransitions(),
|
||||
transitionsBetween(bottomRight, topRight).getTransitions());
|
||||
if ((dimension & 0x01) == 1) {
|
||||
// it can't be odd, so, round... up?
|
||||
dimension++;
|
||||
}
|
||||
dimension += 2;
|
||||
|
||||
BitMatrix bits = sampleGrid(image, topLeft, bottomLeft, bottomRight, dimension);
|
||||
|
|
Loading…
Reference in a new issue