C++ fixes for r2239. Closes 1299

git-svn-id: https://zxing.googlecode.com/svn/trunk@2333 59b500cc-1b3d-0410-9834-0bbf25fbcc57
This commit is contained in:
smparkes@smparkes.net 2012-06-26 18:19:57 +00:00
parent afb81b1625
commit f6840498b3
2 changed files with 4 additions and 4 deletions

View file

@ -266,7 +266,7 @@ Processing: ../core/test/data/blackbox/ean13-5/14.png ... FAILED
Detected: zxing::ReaderException: No code detected
Processing: ../core/test/data/blackbox/ean13-5/15.png ... FAILED
Expected: 9780446579803
Detected: zxing::ReaderException: No code detected
Detected: zxing::IllegalArgumentException: Invalid position (ReedSolomonDecoder)
Processing: ../core/test/data/blackbox/ean13-5/16.png ... FAILED
Expected: 9780446579803
Detected: zxing::ReaderException: No code detected
@ -1039,13 +1039,13 @@ Processing: ../core/test/data/blackbox/aztec-2/08.png ... FAILED
Detected: zxing::ReaderException: No code detected
Processing: ../core/test/data/blackbox/aztec-2/09.png ... FAILED
Expected: mailto:zxing@googlegroups.com
Detected: zxing::IllegalArgumentException: Invalid position (ReedSolomonDecoder)
Detected: zxing::ReaderException: No code detected
Processing: ../core/test/data/blackbox/aztec-2/10.png ... FAILED
Expected: mailto:zxing@googlegroups.com
Detected: zxing::ReaderException: No code detected
Processing: ../core/test/data/blackbox/aztec-2/11.png ... FAILED
Expected: mailto:zxing@googlegroups.com
Detected: zxing::IllegalArgumentException: Invalid position (ReedSolomonDecoder)
Detected: zxing::ReaderException: No code detected
Processing: ../core/test/data/blackbox/aztec-2/12.png ... FAILED
Expected: mailto:zxing@googlegroups.com
Detected: zxing::ReaderException: No code detected

View file

@ -288,7 +288,7 @@ Ref<ResultPoint> Detector::correctTopRight(Ref<ResultPoint> bottomLeft,
Ref<ResultPoint> bottomRight, Ref<ResultPoint> topLeft, Ref<ResultPoint> topRight,
int dimension) {
float corr = distance(bottomLeft, bottomRight) / (float) dimension;
float corr = distance(bottomLeft, topLeft) / (float) dimension;
int norm = distance(topLeft, topRight);
float cos = (topRight->getX() - topLeft->getX()) / norm;
float sin = (topRight->getY() - topLeft->getY()) / norm;