Open ghost opened 9 years ago
Thanks for reporting this issue. We will take a look.
Thanks WACMemphis. Do you need Code-128 to detect less than 6 chars? What's the application?
@juliangsf Yes, I would need to be able to detect any valid barcode. AFAIK, there is no minimum length requirement for Code-128. The reason for this is that our users should be able to use all the barcodes they define. We specify which kind of barcodes they can use (Code-128, QR, EAN-8/13, etc.) and they can use any valid barcode of these types. Consequently, we'd need to be able to scan/detect them.
Detecting shorter barcodes requires making some tradeoffs that would increase the false positive rate. We may be able to mitigate this with some careful tuning, but we still have to make sure not to degrade quality for other users and that takes time.
Ok, so I'll stick to ZXing in the meantime.
Unfortunately, there's no workaround for the 6 character limit.
We expect a future release will lower or remove the limit, but have no target date to announce right now.
I have a doubt that in future if this issue is fixed, do I need to update Google play sdk in my application or it will be automatically updated in user device.
Nothing in the SDK code compiled into your application is involved in the six-character limit, and the fixed code would be rolled out automatically.
Thanks pchx.
@pchx is there an update on this issue?
I was looking into integrating the Vision API today for an app but noticed that it wasn't detecting barcodes with 5 digits and a Google search lead me to this issue. I am going to have to hold off until this issue is resolved before I can use the Vision API.
@michaelcarrano same here. I wanted to use the Vision API as well, but without <6 digit barcode support I won't be able to.
No target date to announce yet, but we're working on it.
The new minimum length will be 2 characters; single digit codes will not be recognized (I'd be curious to hear if anyone needs this).
Ideally, I'd even need single digit barcodes for my projects (numbers 1 to 9).
But 2 is an enormous improvement already. Great work!
The latest version of our Barcode API (part of Google Play Services 10.0) reduces the minimum length for most 1D barcodes to two characters.
Thanks for your patience!
@pchx Congratulations, that's a great improvement!
However, I don't understand why this issue has been closed as the OP is asking for any barcode which would mean a minimum length of 1 character. I myself will still not be able to use this great library because of this, as I need it to be able to detect even single character barcodes.
Right, good point.
Would it work for your use case if you padded numbers to two digits (i.e. 01-09)?
@pchx Unfortunately, no. The application I'm developing allows the user to use any valid barcode, i.e. anything they like as long as it's valid and one digit barcodes are valid.
@pchx "No target date to announce yet, but we're working on it.
The new minimum length will be 2 characters; single digit codes will not be recognized (I'd be curious to hear if anyone needs this)."
I'm afraid, I will be the first one that need to read single digit to be recognized. My case is, to read image from tax paper, and make an automation based on tax paper image input. And on my country, the label is Left Justified, and the number is Right Justified (on the same row). The problem is occurred, when some tax is 0 in value. I can make an assumption, when the ocr result is null on that image rectangle section, I set the tax value as 0. But too bad, value 1 until 9 is also return null. Makes me cannot make an assumption based on char is failed to detect.
Can you suggest me something to get this problem done? Some work around? Or some tweak on the library?
Many thanks before.
I'm not quite sure if this is a bug or a matter of proper configuration, but I've been running the sample code from this github and tried it on some barcodes I generated.
In general it works very well, but when using Code-128, there seems to be a minimum number of "letters" the barcode needs to contain before the barcode reader detects it.
I've attached a screenshot visualizing the issue: