B. Image binarization algorithm
A binarization method which global and local information
are used together is proposed in this paper. The global
threshold is got by the prior knowledge of barcode first, and
then the difference value of the mean of sub-regions and initial
image is calculated as the threshold range of sub-regions. At
last, the threshold is got using OTSU method in this range. The
experimental result shows that the performance of our
algorithm is well when the input image is non-uniformly.