Question

I generated about 1300 .png files for various QR codes using the rqrcode gem, all very similar in terms of content (version 2, ascii encoding, level M data correction). Of those, about 2% couldn't be scanned by the ZXing software either on my local machine or on the website http://zxing.org/w/decode.jspx. I tried another online site and got the same results.

The failed QR codes scan fine using the Android app on my phone produced by the ZXing team. I've tried a variety of different image formats and higher sampling rates, none of which makes a difference. Any guidance on how to debug this would be appreciated. I've attached one of the failed images below:

z

Was it helpful?

Solution

It is almost certainly a false positive finder pattern, which is much easier to find when the image is 'pure' like this. Try the PURE_BARCODE hint for images like this, as it will be much faster and should work on anything. But it's only for non-photos with only a barcode on a white field.

See also https://code.google.com/p/zxing/issues/detail?id=1745

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top