Page 1 of 1

DataMatrix problem

Posted: Sat May 26, 2012 11:49 pm
by lbleicher
12.png
single barcode image
12.png (10.24 KiB) Viewed 6449 times
Hi-

I have created a Datamatrix decoder (in the code section below) but it fails to recognize a single barcode.

Am I doing something foolish? All I get is "No barcode detected!"

Source file is attached, plus a parsed out subimage which also fails with my code and the example barcode_recognition.exe

Thanks for your help,
Leo

Code: Select all

        Dim ImageID As Integer
        Dim oGdPictureImaging As New GdPicture.GdPictureImaging

        Dim oLicenseManager As New GdPicture.LicenseManager 'Go to http://evaluation-gdpicture.com 
        oLicenseManager.RegisterKEY("xxx")

        ImageID = oGdPictureImaging.CreateGdPictureImageFromFile(datamatrixPath)
        If ImageID <> 0 Then
            If oGdPictureImaging.BarcodeDataMatrixReaderDoScan(ImageID) = GdPictureStatus.OK Then
                Dim BarcodeCount As Integer = oGdPictureImaging.BarcodeDataMatrixReaderGetBarcodeCount()
                If BarcodeCount > 0 Then
                    For i As Integer = 1 To BarcodeCount
                        node.GetProperties().Define("datamatrix_" & i, oGdPictureImaging.BarcodeDataMatrixReaderGetBarcodeValue(i))
                    Next
                Else
                    node.GetProperties().Define("datamatrix", "No barcode detected!")
                End If
                oGdPictureImaging.BarcodeDataMatrixReaderClear()
            End If
            oGdPictureImaging.ReleaseGdPictureImage(ImageID)
        End If

Re: DataMatrix problem

Posted: Wed May 30, 2012 11:23 am
by Loïc
Hello,

As my humble opinion it is totally impossible to decode your barcode. The image is too dark, and the symbols are too much altered.

I can't provide any solution for such scenario. The problem has to be fixed in the way you capture the image with your camera.

Kind regards,

Loïc