Uploaded image for project: 'PDFBox'
  1. PDFBox
  2. PDFBOX-5816

PDFRenderer.renderImage creates black line clouds on the text

    XMLWordPrintableJSON

Details

    Description

      For some PDF files, the PDFRenderer.renderImage method creates an image with black line clouds on the text that are not visible in the original PDF. Unfortunately, the files contain personal data, so I cannot make them available for examination. The attached screenshots hopefully give a first impression of the problem. Is there any way for me to narrow down the problem or analyze the PDF so that I can provide more information?

      The source code does something like this:

      try (PDDocument document = PDDocument.load(pdfData)) {
        PDFRenderer pdfRenderer = new PDFRenderer(document);
        int pageCount = document.getNumberOfPages();
        for (int pageIndex = 0; pageIndex < pageCount; ++pageIndex) {
          PDPage page = document.getPage(pageIndex);
          BufferedImage pageImage = pdfRenderer.renderImage(pageIndex);
      ...
        }
      }

      Attachments

        1. image003.png
          19 kB
          ExSp
        2. image0032.png
          13 kB
          ExSp

        Issue Links

          Activity

            People

              Unassigned Unassigned
              Extern ExSp
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: