zbar

by Will Glynn

github.com/willglynn/ruby-zbar

DESCRIPTION:

Ruby bindings for ZBar, a barcode recognition library.

SYNOPSIS:

require 'zbar'

ZBar::Image.from_jpeg(File.read('test.jpg')).process
=> [#<Zbar::Symbol:0x10147c668
  @addon="",
  @data="9876543210128",
  @location= [...],
  @quality=15,
  @symbology="EAN-13">]

REQUIREMENTS:

  • FFI

  • ZBar, probably 0.10 or more

ZBar can be obtained from zbar.sourceforge.net.

DOWNLOAD/INSTALL:

From gemcutter:

[sudo] gem install zbar

From github:

git clone git://github.com/delta407/ruby-zbar.git
cd ruby-zbar
rake install

LIMITATIONS:

Doesn’t expose all ZBar functionality, including:

  • No video functions

  • No low-level interfaces (scanner, decoder)

Note on Patches/Pull Requests

  • Fork the project.

  • Make your feature addition or bug fix.

  • Add tests for it. This is important so I don’t break it in a future version unintentionally.

  • Commit, do not mess with rakefile, version, or history. (if you want to have your own version, that is fine but bump version in a commit by itself I can ignore when I pull)

  • Send me a pull request. Bonus points for topic branches.

Copyright © 2010-2013 Will Glynn. See LICENSE for details.