How to Improve the scanning detection?

657 views
Skip to first unread message

Eric Tang

unread,
Aug 13, 2013, 4:18:15 AM8/13/13
to zx...@googlegroups.com
Our website has a designed QRCode . But ZXing decode it hardly

But to my surprised, the most used QRCode Scanner in China, Wechat, solved it seckilling
I'm really confused...SO I saved three images. (source Image, greying Image, and the binary Image.

It's easy to obvious the problem, about the three find patterns' color.

But why Wechat can detect it ? 

Does it exist  an algorithm can find the qrcode without find-patterns? 

Er....May Be Used Pattern Recognition Or train a  classifier? I don't think so....

So How to Optimization the detector?

My poor English writing...I hope everyone will understand what i say.........

Sean Owen

unread,
Aug 13, 2013, 5:28:30 AM8/13/13
to zx...@googlegroups.com
I'm not sure I understand. Why doesn't this barcode scan? probably because it is not quite printed properly. The light-blue finder pattern border is far too light compared to the other modules.

Eric Tang

unread,
Aug 13, 2013, 5:41:16 AM8/13/13
to zx...@googlegroups.com
Er.....I think I understand why Zxing Can't Detect the barcode...From the binary image, We know the find-patterns is not clearly...

The problem is after greying, background's color influenced the global histogram binary...

But Wechat can scan this barcode...I have know idea, how it works

Sean Owen

unread,
Aug 13, 2013, 7:42:23 AM8/13/13
to zx...@googlegroups.com
You could change the image processing code to assume that colored regions are basically black. That would make this work. But then you would not be able to scan dark-on-light color barcodes.

Eric Tang

unread,
Aug 13, 2013, 8:09:41 AM8/13/13
to zx...@googlegroups.com
En, This method works on this case.

I think If I get the QRCode region before global histogram binary(not use the find patterns, use other algorithms like classifier, convex hull, etc),  maybe get a better result?

Sean Owen

unread,
Aug 13, 2013, 10:01:26 AM8/13/13
to zx...@googlegroups.com
Yes, but my point is that changing it to scan this barcode makes it not scan other barcodes.
I would not recommend this change since the barcode here really isn't properly printed.

Eric Tang

unread,
Aug 13, 2013, 10:34:41 AM8/13/13
to zx...@googlegroups.com
Thanks a lot, for your patience. 

But my question is : how to optimize the detector Algorithm.

I know, this bar code is "bad design"
But there exist an app can detect this barcode, at same time, it detect others very well

So, Why ZXing can't? Can we optimize it?

Sean Owen

unread,
Aug 14, 2013, 2:53:14 AM8/14/13
to zx...@googlegroups.com
I've already answered this: because it probably accepts lighter regions as dark, or treats colored regions as dark. If that's true, go find a black-on-color barcode and try to scan it, and see if it works or not. If that's true, it's just trading one problem for another. No you can't 'optimize' that.
Reply all
Reply to author
Forward
0 new messages