I'm creating a program for localizing types of barcodes. (I know plenty exist, that's not the question :) ) I'm focusing for the time being on 1D barcodes.
The difficulty I have is that the barcodes I need to be able to locate could be situated anywhere within an image with other information (text/images/...), inequal lighting conditions (-> gradients), and barcodes could be scaled and orientated in any way.
[Edit] Unlike most barcode-related cases however, my application does not need to be run on a smartphone, so can allow myself some processing bandwidth
I have been researching as much as possible in books and publications, but think it's time to ask the experts...
What is the most appropriate approach for reliably localising 1D barcodes in difficult environments?
Currently, I'm applying otsu thresholding, basic edge detection and hough transforms.
Problems i currently face:
- otsu thresholding is global and doesn't handle local gradients on large images well. are there localized algorithms that exist?
- hough locates the lines of the barcodes, but also other items (in particular text), and it's difficult to filter only the barcodes (thresholding the min number of pixels in the line throws out a lot, but also throws out the smaller barcodes)
Could anyone point me in the right direction?
I'm wondering about Fourier and Gabor filters, but they seem more complex, so want opinions before i start.
PS: I am doing everything in Octave and Java