Set Target Regions for Recognition

Overview

Developers can specify explicitly not only the desired types but also a target region or regions in the source image. This allows optimizing the scanning process by avoiding areas without barcodes. Target regions can be determined using a class called Quadrangle. Setting target regions allows improving recognition efficiency and avoiding the regions without any barcodes. Target areas have to be determined accurately as the Aspose library applies heuristic approaches to identify target barcode detection areas. Focusing on too many image regions can lead to recognition efficiency deterioration.

Set Unique Target Region

To set one target area for barcode recognition, it is necessary to create an object of the Quadrangle type and then pass it to the BarCodeReader constructor or the setBarCodeImage method.

Set Several Target Regions

It is also possible to set several target areas for barcode detection within one source image. This can be done in the same way as described above for one target region, i.e., using the BarCodeReader constructor or the setBarCodeImage method.