Page 1 of 1

PDF417 recognition won't work

Posted: Mon Apr 29, 2013 2:30 pm
by Halla602
Hi, I created a sample using GdPicutre 9.4 version, where I open empty .pdf, create 4 BarCodes (1d, QR, PDF417 & DataMatrix), save the file and then try to process it through BarCode recognition.

However, I am only able to read 1D and QR codes, PDF417 & DataMatrix cannot be found. The project is in C#, here is a sample how i try to find any codes..

Code: Select all

ImageID = Pdf.RenderPageToGdPictureImage(400, true);

status = GdPictureImaging.BarcodePDF417ReaderDoScan(ImageID, BarcodePDF417ReaderScanMode.BestQuality);
                    if (status == GdPictureStatus.OK)
                    {
                      temp_count = GdPictureImaging.BarcodePDF417ReaderGetBarcodeCount();
                      status = Pdf.GetStat();

                      for (int c = 1; c <= temp_count; c++)
                      {
                        string data = GdPictureImaging.BarcodePDF417ReaderGetBarcodeValue(c).ToString();
                        status = Pdf.GetStat();
                        // process data
                      }
And the same way for QR, 1D and DataMatrix, I then format the output and print it. For DataMatrix and PDF417, the temp_count stays at 0, even if they are clearly generated in the input file. When I tried other random online readers, they were able to read the barcodes and retrieve data successfully.



The code for BarCode generating is here, the same pattern is used for QR, 1D and DataMatrix with different EncodingMode enums and other parameters, but simmilar to this.:

Code: Select all

else if (Placement[i].type == Barcode_Subtype.Barcode_PDF417)
              {
                BarcodePDF417EncodingMode EncodingMode = BarcodePDF417EncodingMode.BarcodePDF417EncodingModeText;
                BarcodePDF417ErrorCorrectionLevel CorrectionLevel = BarcodePDF417ErrorCorrectionLevel.BarcodePDF417ErrorCorrectionLevelAuto;

                status = pdf.DrawBarcodePDF417(Data, EncodingMode, CorrectionLevel, 30, 3, 4, 2, Placement[i].X, Placement[i].Y, System.Drawing.Color.Black);
              }

If you can help me find any errors, I would be really glad. I attached the generated file to this post.

Re: PDF417 recognition won't work

Posted: Mon Apr 29, 2013 7:10 pm
by Loïc
Hello,

Could you share the whole code used to generate the PDF ?

Kind regards,

Loïc

Re: PDF417 recognition won't work

Posted: Wed May 01, 2013 6:18 pm
by Loïc
Hello,

We've identified and fixed a problem in the 2D barcode generator. The next minor version (9.4.8) will have this problem fixed.

Waiting for, just set the PDF origin to top-left as a workaround.

Kind regards,

Loïc

Re: PDF417 recognition won't work

Posted: Thu May 02, 2013 3:30 pm
by Halla602
Thank you very much, when will you release this new version ?

Re: PDF417 recognition won't work

Posted: Tue May 14, 2013 7:55 pm
by Loïc
Hello,

Sorry for the late reply. The new release fixing this issue is available.
Download link: https://www.gdpicture.com/download.php

Best regards,

Loïc