本文主要是介绍ubuntu zbar,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!
下载zbar:
wget http://downloads.sourceforge.net/project/zbar/zbar/0.10/zbar-0.10.tar.gz
编译zbar:
$tar xvf zbar-0.10.tar.gz
$cd zbar-0.10
$ ./configure --enable-shared --disable-video --without-python --without-gtk --without-qt --without-imagemagick CFLAGS=""
$make
$sudo make install
$sudo ldconfig
编译运行example:
$cd example
$gcc scan_image.c -o scan_image -lzbar -lpng
$./scan_image barcode.png
输出结果:
decoded EAN-13 symbol "9876543210128"
这篇关于ubuntu zbar的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!