False Positives
How to remove false positives?
False Positives are an issue with text documents containing 1D barcodes:
1. Tell IronBarCode to read only the barcode formats which you expect.
- Change IronBarCode.BarcodeEncoding.All to IronBarCode.BarcodeEncoding.your-expected-barcode-type
- A complete list of options is shown here: https://ironsoftware.com/csharp/barcode/object-reference/api/IronBarCode.BarcodeEncoding.html
2. Tricks to remove false positives:
- Scale the input image in size up/down a little in size, so now we read 2 images for barcodes - normal.png and scaled.png
- Ignore barcodes which are not found in both images
A small note: this process is slower, though will produce fewer false positive results