views:

1841

answers:

5

I'm seeking a library, technique or advice on how to read an EAN-13 barcode from an image (including ISBN,and ISSN encodings). The image would come from a mobile phone or webcam, so resolution may be quite poor and not well aligned.

I'm specifically interested in something that could be used from ruby on rails, but answers for other languages are welcome. Open Source solutions preferred.

Leading solutions to date:

  1. ZBar (previously known as Zebra - h/t @bgbg, @Natim) - implemented in C with interfaces for Python, Perl, and C++
  2. ZXing (h/t @codr) - implemented in Java (J2SE and Android) with other modules/ports in varying states of development (JavaME, C#, C++, JRuby, RIM, iPhone/Objective C)
A: 

take a look at http://www.savefile.com/files/1496871

...and what is it?
Huppie
Perfectly valid - but to get to it I had to have something to open the tar file (hello WinRAR) and it's C so you'll need something for that also. (In case you didn't include it in your VS install - or for those of you without VS, well, you have compilers too I would guess <smile> )
Doug L.
Honestly, my first thought was the download file had a high chance of being a virus or trojan. Link to an anonymous file on savefile, with no further description? My finger is hovering over the "offensive?" link.... @SEyYl, if this is a legit post, recommend you edit and clarify.
tardate
...and then it doesn't do anything!! Just 'converts from color to b/w'. A waste of time.
paul
+6  A: 

The zebra barcode reader (http://zebra.sourceforge.net/) is a small, layered bar code scanning and decoding library implemented in C (C++ wrappers are also provided). It supports many popular symbologies (types of barcodes), including EAN-13. However, I'm not aware about any Ruby bindings. The library is available under the GPL

bgbg
@bgbg good tip, thanks. looks promising even though not for ruby
tardate
Doesn't exists anymore. Look at http://sourceforge.net/projects/zbar/
Natim
Thanks @Natim. Just to clarify for all, I discovered ZBar is actually the Zebra project after a name change (done "..for compelling reasons..";-)
tardate
I liked Zebra much better
bgbg
+2  A: 

You might want to try this if it's to allow your site's visitors to scan stuff, I think it's embeddable in your own site, but I've never used it : http://en.barcodepedia.com/

Seldaek
I see a data api is in the roadmap http://en.barcodepedia.com/about. One to watch ... seems like it could be an ideal solution in the future.
tardate
A: 

We use the Softek library.

Very pleased with the results.

Rob
+3  A: 

This project might be what you're looking for: ZXing

codr