Download and install the ClearImage SDK
Use Visual Studio C++ ClearImage example project or follow the instruction below. When using the example project, copy ClearImage.dll in the executable folder or in the PATH.
In your Visual Studio C++ project:
- Include a copy of C:\Program Files (x86)\Inlite\ClearImageSDK\ClearImage.wrapper.hpp in every source file that uses ClearImage API.
- Add a copy of C:\Program Files (x86)\Inlite\ClearImageSDK\ClearImage.lib to your project's Properties->Linker->Input->Additional Dependencies entry.
- Place ClearImage.dll in a location where it can be found according to Microsoft's DLL search order rules. Typically it is a working folder where your application started from. The ClearImage.dll is installed in:
- 32-bit version from C:\Program Files (x86)\Inlite\ClearImageSDK\win32\ClearImage.dll
- 64-bit version from C:\Program Files (x86)\Inlite\ClearImageSDK\x64\ClearImage.dll
This code demonstrates the use of ClearImage DLL API. Runtime errors are reported in ExceptionCI object.
While developing your application, you can combine code examples on this page with methods described in ClearImage API documentation . DLL API, as exposed through ClearImage.wrapper.hpp, is substantially similar to COM API and .NET API Inlite.ClearImage namespace.
ClearImage DLL API reports errors as an ExceptionCI object.
This example reads code 39 and code 128 barcodes. Set barcode types used in your application. Setting reader->AutoDetect1D=true; automatically finds the barcode type, but it is slower and is not recommended for production.
This example reads PDF417, DataMatrix, and QR code. 2D barcodes might contain binary data available in CiBarcode->Data property as std::vector<char>
This example reads Postal Barcodes from an image file page.
This example reads the Driver's License barcode from an image file page.
This example reads barcodes from a single-page file or all pages of a multi-page image file.
This example uses some of the most popular image-processing functions. In a production application, the specific sequence of functions should be selected based on specific application needs.
This example repairs all images in a multi-page file and saves the result in the fileOut file.