.\" Automatically generated by Pod::Man 4.14 (Pod::Simple 3.40) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" Set up some character translations and predefined strings. \*(-- will .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left .\" double quote, and \*(R" will give a right double quote. \*(C+ will .\" give a nicer C++. Capital omega is used to do unbreakable dashes and .\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff, .\" nothing in troff, for use with C<>. .tr \(*W- .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' .ie n \{\ . ds -- \(*W- . ds PI pi . if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch . if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch . ds L" "" . ds R" "" . ds C` "" . ds C' "" 'br\} .el\{\ . ds -- \|\(em\| . ds PI \(*p . ds L" `` . ds R" '' . ds C` . ds C' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is >0, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .\" .\" Avoid warning from groff about undefined register 'F'. .de IX .. .nr rF 0 .if \n(.g .if rF .nr rF 1 .if (\n(rF:(\n(.g==0)) \{\ . if \nF \{\ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . if !\nF==2 \{\ . nr % 0 . nr F 2 . \} . \} .\} .rr rF .\" ======================================================================== .\" .IX Title "ZBar 3pm" .TH ZBar 3pm "2021-02-13" "perl v5.32.1" "User Contributed Perl Documentation" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH "NAME" Barcode::ZBar \- Perl interface to the ZBar Barcode Reader .SH "SYNOPSIS" .IX Header "SYNOPSIS" setup: .PP .Vb 1 \& use Barcode::ZBar; \& \& my $reader = Barcode::ZBar::Processor\->new(); \& $reader\->init(); \& $reader\->set_data_handler(\e&my_handler); .Ve .PP scan an image: .PP .Vb 5 \& my $image = Barcode::ZBar::Image\->new(); \& $image\->set_format(\*(Aq422P\*(Aq); \& $image\->set_size(114, 80); \& $image\->set_data($raw_bits); \& $reader\->process_image($image); .Ve .PP scan from video: .PP .Vb 3 \& $reader\->set_visible(); \& $reader\->set_active(); \& $reader\->user_wait(); .Ve .PP collect results: .PP .Vb 4 \& my @symbols = $image\->get_symbols(); \& foreach my $sym (@symbols) { \& print("decoded: " . $sym\->get_type() . ":" . $sym\->get_data()); \& } .Ve .SH "DESCRIPTION" .IX Header "DESCRIPTION" The ZBar Bar Code Reader is a library for scanning and decoding bar codes from various sources such as video streams, image files or raw intensity sensors. It supports \s-1EAN\-13/UPC\-A,\s0 UPC-E, \s-1EAN\-8,\s0 Code 128, Code 93, Code 39, Codabar, Interleaved 2 of 5 and \s-1QR\s0 Code. .PP These are the bindings for interacting directly with the library from Perl. .SH "REFERENCE" .IX Header "REFERENCE" .SS "Functions" .IX Subsection "Functions" .IP "\fBversion()\fR" 4 .IX Item "version()" Returns the version of the zbar library as "\fImajor\fR.\fIminor\fR". .IP "\fBincrease_verbosity()\fR" 4 .IX Item "increase_verbosity()" Increases global library debug by one level. .IP "set_verbosity(\fIlevel\fR)" 4 .IX Item "set_verbosity(level)" Sets global library debug to the indicated level. Higher numbers give more verbosity. .IP "parse_config(\fIconfigstr\fR)" 4 .IX Item "parse_config(configstr)" Parse a decoder configuration setting into a list containing the symbology constant, config constant, and value to set. See the documentation for \f(CW\*(C`zbarcam\*(C'\fR/\f(CW\*(C`zbarimg\*(C'\fR for available configuration options. .SS "Constants" .IX Subsection "Constants" Width stream \*(L"color\*(R" constants: .IP "\s-1SPACE\s0" 4 .IX Item "SPACE" Light area or space between bars. .IP "\s-1BAR\s0" 4 .IX Item "BAR" Dark area or colored bar segment. .PP Decoder configuration constants: .IP "Config::ENABLE" 4 .IX Item "Config::ENABLE" .PD 0 .IP "Config::ADD_CHECK" 4 .IX Item "Config::ADD_CHECK" .IP "Config::EMIT_CHECK" 4 .IX Item "Config::EMIT_CHECK" .IP "Config::ASCII" 4 .IX Item "Config::ASCII" .IP "Config::MIN_LEN" 4 .IX Item "Config::MIN_LEN" .IP "Config::MAX_LEN" 4 .IX Item "Config::MAX_LEN" .IP "Config::POSITION" 4 .IX Item "Config::POSITION" .IP "Config::X_DENSITY" 4 .IX Item "Config::X_DENSITY" .IP "Config::Y_DENSITY" 4 .IX Item "Config::Y_DENSITY" .PD .PP Symbology modifier constants: .IP "Modifier::GS1" 4 .IX Item "Modifier::GS1" .PD 0 .IP "Modifier::AIM" 4 .IX Item "Modifier::AIM" .PD .PP Symbol orientation constants: .IP "Orient::UNKNOWN" 4 .IX Item "Orient::UNKNOWN" .PD 0 .IP "Orient::UP" 4 .IX Item "Orient::UP" .IP "Orient::RIGHT" 4 .IX Item "Orient::RIGHT" .IP "Orient::DOWN" 4 .IX Item "Orient::DOWN" .IP "Orient::LEFT" 4 .IX Item "Orient::LEFT" .PD .SH "SEE ALSO" .IX Header "SEE ALSO" Barcode::ZBar::Processor, Barcode::ZBar::ImageScanner, Barcode::ZBar::Image, Barcode::ZBar::Symbol, Barcode::ZBar::Scanner, Barcode::ZBar::Decoder .PP \&\fBzbarimg\fR\|(1), \fBzbarcam\fR\|(1) .PP http://zbar.sf.net .SH "AUTHOR" .IX Header "AUTHOR" Jeff Brown, .SH "COPYRIGHT AND LICENSE" .IX Header "COPYRIGHT AND LICENSE" Copyright 2008\-2010 (c) Jeff Brown .PP The ZBar Bar Code Reader is free software; you can redistribute it and/or modify it under the terms of the \s-1GNU\s0 Lesser Public License as published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.