Recently, we contributed a barcode recognition algorithm to opencv_contrib. In this blog post, we will introduce the algorithm and how to use it. Abou

Recognizing one-dimensional barcode using OpenCV

submited by
Style Pass
2021-06-28 14:30:08

Recently, we contributed a barcode recognition algorithm to opencv_contrib. In this blog post, we will introduce the algorithm and how to use it.

About the authors: Junhao Liang and Tianqi Wang are undergraduates at Southern University of Science and Technology in Shenzhen. Their main research interest is computer vision

Barcodes are a major technique to identify commodities in real life.  A common barcode is a pattern of parallel lines arranged by black bars and white bars with vastly different reflectivity and contrast. Barcode recognition is the process of scanning the barcode in the horizontal direction to get a string of binary codes composed of bars of different widths and colors. This data is the code information of the barcode. The content of the barcode can be decoded by matching with various barcode encoding methods. Currently our code supports EAN-13, EAN-8 and UPC-A encoding methods.

The EAN-13 barcode is based on the UPC-A standard, which was first implemented in Europe by the International Item Coding Association and later gradually spread worldwide. Most of the common goods in life use the EAN-13 barcode. For more detail see EAN – Wikipedia. For convenience, we’re going to use EAN-13 as an example in the following.

Leave a Comment