Comments (6)
Good question. All the samples are failing for me too. My first guess is there's something wrong with ZXing because Binary Eye just gives an image to ZXing. On the other hand, ZXing has tests for MaxiCode 🤔
from binaryeye.
Well, finally found out that ZXing (in version 3.3.3, the last version we can use for Android apps that should run below Android 7.0 Nougat, see here) can only read MaxiCodes if it's in PURE_BARCODE mode.
PURE_BARCODE
means the barcode is expected to be unrotated and not skewed in the input image. Of course, this isn't usually true for a camera frame.
From MaxiCodeReader.java:
@Override
public Result decode(BinaryBitmap image, Map<DecodeHintType,?> hints)
throws NotFoundException, ChecksumException, FormatException {
DecoderResult decoderResult;
if (hints != null && hints.containsKey(DecodeHintType.PURE_BARCODE)) {
BitMatrix bits = extractPureBits(image.getBlackMatrix());
decoderResult = decoder.decode(bits, hints);
} else {
throw NotFoundException.getNotFoundInstance();
}
....
Unfortunately, the docs are silent on this 😞
Now, I've did a couple of tests and indeed could read a couple of MaxiCodes when PURE_BARCODE
is set. Of course, setting PURE_BARCODE
makes reading other barcodes much worse (like QR Codes and DataMatrix and probably others as well) 😬
So the only solution I see would be to have a special MaxiCode Reader "mode", which would be rather ugly, of course.
Alternatively, it would also be possible to scan every other frame with PURE_BARCODE
set but that also would make performance for all other codes a bit worse 🤔
from binaryeye.
Thank you for the reply. At least now we know what's going on! I agree having an option to switch "modes" sounds ugly. What do you think about doing a second pass on the same image data with the said PURE_BARCODE
option set in case the first (normal) pass finds nothing? Or would that slow down the scanning too much?
from binaryeye.
Unfortunately, yes, doing an extra pass would slow down scanning. Especially on low end devices. So I rather wouldn't do it by default.
from binaryeye.
Not by default, but I feel here's where a checkbox setting would come in handy. Switch between faster but less broad and slower but with more codes supported.
from binaryeye.
Could the PURE_BARCODE
be auto-enabled when "Restrict format" is set to MAXICODE?
from binaryeye.
Related Issues (20)
- [Enhancement request] FrameQR HOT 2
- Codabar scans omit start/stop codes HOT 1
- Conflict between Google Play Store and F-Droid HOT 5
- ZXing-CPP Wrapper: Request for different versioning format HOT 4
- [Feature request] Display hash at the bottom of the results HOT 7
- INSTALL_FAILED_CPU_ABI_INCOMPATIBLE with ARMv6 device HOT 2
- BinaryEye from F-droid cannot be installed on Amazon tablet HOT 1
- Null character is not handled correctly from escaped string input at Compose barcode HOT 1
- [Bug] A few selected Codes from history didn't export HOT 1
- Does not recognize linear barcodes in white on black HOT 3
- Display tab character HOT 4
- [FR] Increase the brightness of screen when displaying QR code HOT 1
- Display eBay sold results of the scanned UPC HOT 1
- Is it possibale to add a warning lists? HOT 2
- History export need the scan date and time HOT 1
- button change HOT 2
- Open link in incognito mode HOT 3
- Request for adding to Accrescent app store) HOT 2
- Need to scan QR code twice when opening intent from PWA/Installed web app HOT 6
- [Feature] IMb - Intelligent Mail Barcode HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from binaryeye.