Decode Unreadable Barcodes with Dynamsoft Barcode Reader's Custom Scan Parameters

< Back

Inverted DPM Codes

Issue: Direct Part Marks (DPM) are codes, symbols, and texts that are etched or printed directly onto the surface of a part, which has a different texture from marks printed on paper. They are often inverted on a dark surface.

Solution: Enable the DPM reading mode and invert the color of the image using GrayscaleTransformationModes.

JSON Template:

{
  "Version": "3.0",
  "ImageParameter": 
  {
    "Name": "Test1",
    "GrayscaleTransformationModes":[
      {
        "Mode":"GTM_INVERTED"
      }
    ],
    "DPMCodeReadingModes":[
      {
        "Mode":"DPMCRM_GENERAL"
      }
    ],
    "DeblurLevel": 9,
    "Timeout": 99999
  }
}

×

Binarized image produced by Dynamsoft Barcode Reader:

Template for Dynamsoft Barcode Reader:

JavaScript Code Snippet to Use the Template:

barcodeReader.initRuntimeSettingsWithString(template);
Single
Clean
Direct part marking
Other
Data Matrix

Download Our Free Barcode Test Sheet

Curious about how our Dynamsoft Barcode Scanner SDK works in real-world applications? Download our free Barcode Test Sheet, a comprehensive PDF packed with different types of barcodes, batched barcodes or even damaged codes ready to be scanned. Explore the real-world examples to see how Dynamsoft can boost your scanning performance and tackle the challenges of difficult-to-read barcodes.

Barcode Test Sheet
barcode-test-sheet-illus.png