Technical Information

TBR-Targeted Barcode Reader

Inlite’s Targeted Barcode Reader (TBR) delivers the highest recognition rate and/or speed for customer-specific sets of images. In addition to several of-the-shelf specialized algorithms, Inlite can rapidly and cost-effectively address unique customers' barcode recognition requirements.

TBR Code

TBR Code identifies an algorithm to read barcodes on a page.

Use of TBR Code is optional. The default algorithm, if the TBR Code is not set, reads most of the real-life barcodes.

TBR Code – is a numeric value that identifies the TBR reader. The codes are:

  • 0 – Default code. If set, it forces the use of the default algorithm.
  • 100-199 – Internally predefined codes (some of the codes are reserved for future use)
  • 400-499 – External TBR Codes defined in ci.ini file

Identify the best TBR codes

To identify the best TBR codes for your set of images, use these tools and methods:

  • Use the TBR Wizard application to find the best TBR code(s) for single or multiple images.
  • Use the TBR Wizard dialog box in the ClearImage Demo application to find the best TBR code for a single image.

Activate TBR Code

ClearImage SDK

Set TbrCode property of the readers. For example:

C#
C++
Java
PHP


To use multiple TBR codes, use one of these methods:

  • Repeat reading operations with each TBR code
  • Use external TBR

Notes:

  • If the TBR code is invalid or not applicable to the barcode type, an exception is generated.
  • If a barcode is obtained using a TBR reader, then the <tbr> tag of the barcode’s meta-data contains the TBR code.
  • Do not use image pre-processing with ClearImage Tools or Repair before using ClearImage Reader with TBR code. This might lead to unpredictable results.

Barcode Reader CLI

Set -tbr option value. Multiple TBR codes are set as a comma-separated list. For example:

-tbr=109,107

External TBR Codes

External TBR Codes are defined in the [TBR] section of C:\ProgramData\Inlite\ClearImage\ci.ini file. If this file does not exist, create it in any text editor (e.g., Notepad) With external TBR, users can:

  • Change the default recognition algorithm (TBR 0) to a predefined or an external TBR code without your application code change.
  • Activate multiple TBR codes for a single-read operation.
  • Implement new custom TBR provided by Inlite's support.

Format

The format of the External TBR definition:

tbrCODE[:READER]=COMMAND[~COMMAND]...

The values in [ ] are optional. The values in italic are variables. Where:

Section

Description

CODE

0 or a 3-digit TBR code

READER

Optionally, limit the type of ClearImage Readers to which code is applied. 1 – Barcode 1d PRO, p – PDF417, d – DataMatrix, q – QR.

COMMAND

Commands executed by TBR code. A tilde character (~) should separate multiple commands. Public commands are:

 

id:text - the text value is for reference purposes only and does not affect the execution

tbr:code - execute TBR identified by the code value.

max:nmb - the maximum number of barcodes to read. If both max:nmb and MaxBarcodes in Find(MaxBarcodes) or BarcodeReader.MaxBarcodes are non-zero, then the minimum value applies.

rd - read barcodes after applying commands that follow the last rd command. For the first rd command, all commands from the start are applied.



Put [TBR] section header before any external TBR definition in C:\ProgramData\Inlite\ClearImage\ci.ini file. For example:

[TBR] tbr0:p=tbr:103 tbr410=max:1~tbr:112~rd~tbr:125~rd~tbr:103~rd

Example: Override default processing

This example changes default processing to TBR 103 for PDF417 reader only

tbr0:p=tbr:103 

This method changes barcode reader behavior without a change of your application code.

Example: Chain several TBR codes

This example reads one barcode using TBR codes 112, 125, and 103. Once the barcode is found (e.g., with code 112), further processing is stopped. Activate TBR Code 410 in your code.

tbr410=max:1~tbr:112~rd~tbr:125~rd~tbr:103~rd

To the same sequence without changing this code, assign this sequence to the default TBR code 0.

tbr0=max:1~tbr:112~rd~tbr:125~rd~tbr:103~rd

Example: Custom TBR codes

Using external TBR, Inlite can quickly deliver an algorithm tailored for processing your specific images. An example of such activation is:

tbr411=id:Acme.2023-04:nxD96psyGAJXsfkmUc..PCArZlQgA

Where

  • 411is a TBR code
  • Acme.2023-04 - is a reference id, typically used for identifying customer and algorithm
  • nxD96ps... - is an encrypted algorithm developed for a customer by Inlite