I experimented with the barcodedetector and related Vision APIs for a week or so, and unfortunately, the conclusion is that they are unreliable. I tested them with ~ 10 devices: Samsung and Nexus tablets / Android phones from 4.4 to 6.01.
The common problem was that I could not decode some QR codes - other applications based on the zxing library, and also the iPhone had no problems decrypting them. Problem QR codes had one of the following “drawbacks”: somewhat distorted time (due to scaling), without a quiet zone, or their raster data had a lower / left beginning (i.e., the image was mirrored).
Also worried that related APIs (like CameraSource) look like errors. Fortunately, the sample barcode reader comes with an open source version, so it can be fixed if necessary. The most obvious mistake is how the resolution of the camera is mapped to view dimensions without taking into account the current orientation. You can clearly see side effects in the sample - a camera preview never fills the activity area, especially in landscape orientation.
Does anyone encounter similar problems? Are there any workarounds for show stops - for example, decoding qr codes?
Thanks.
source share