Java
Download and install the ClearImage SDK.
Add ClearImageJ.jar to CLASSPATH. Typically file is located in C:\Program Files (x86)\Inlite\Libs folder.
Java API uses several methods to locate ClearImage.dll listed below in descending priority.
- Explicit path using the CiServer.loadClearImage(ClearImageDllPath) method.
- Folder specified by -Djava.library.path="ClearImageDllPath" on the java command line.
- Folders specified by the PATH environmental variable
Use the correct 32-bit or 64-bit version of ClearImage.dll, that matches your Java runtime version. ClearImage.dll is located in subfolder of C:\Program Files (x86)\Inlite\ClearImageSDK folder \win32 and \x64
This code demonstrates the use of ClearImage Java API. Runtime errors are reported in Exception object.
While developing your application, you can combine code examples on this page with methods described in ClearImage API documentation .
ClearImage Java API reports errors as an Exception object.
This example reads code 39 and code 128 barcodes. Set barcode types used in your application. Setting reader.setAutoDetect1D(EBoolean.ciTrue); 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 from Bc.getData() as byte[]
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 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.