Analyzing your prompt, please hold on...
An error occurred while retrieving the results. Please refresh the page and try again.
Aspose.BarCode for C++ provides class BarCodeReader that enables barcode recognition from given images for more than 60 symbologies. In general, to perform barcode reading, first, it is necessary to specify the source of an image with barcodes to be detected as a file, a bitmap object, or a stream. Then, it is required to set target symbologies in the DecodeType parameter; otherwise, barcode recognition will take more time, as using the default setting DecodeType.AllSupportedTypes implies looking over all supported symbologies to check for their presence in the source barcode image. In addition, developers can explicitly set the target region/regions in an image for barcode reading. It can be done using a Rectangle object and allows avoiding the unnecessary search for barcodes in the image areas with no barcodes presented by default.
To read barcodes presented in an image using Aspose.BarCode for C++, the following steps need to be taken:
In Aspose.BarCode for C++, barcode recognition is performed through the ReadBarCodes method that returns recognition results in an array of the BarCodeResult type.
To get barcode recognition results, it is necessary to call the ReadBarCodes method that will output an array of the BarCodeResult type. At the same time, it is possible to get access to the current barcode reading output by using the FoundBarCodes property that stores recognition results or the FoundCount parameter that returns the number of barcodes that have been processed.
Class BarCodeReader allows aborting the recognition process in case it is not further feasible. It can be done in two ways. The first option is to use the TimeOut property to interrupt the recognition process in case of exceeding the timeout value. By default, TimeOut is set to 0.
The second way is to call the Abort method in case the recognition process has been launched in the other stream. This method does not block the entire process and returns control immediately.
Both recognition abortion ways result in throwing an exception called RecognitionAbortedException in the case when the recognition process has not been completed.
Analyzing your prompt, please hold on...
An error occurred while retrieving the results. Please refresh the page and try again.