You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@pdfbox.apache.org by "Tilman Hausherr (JIRA)" <ji...@apache.org> on 2014/09/19 10:34:33 UTC

[jira] [Closed] (PDFBOX-2361) Blank pages after conversion images to pdf

     [ https://issues.apache.org/jira/browse/PDFBOX-2361?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Tilman Hausherr closed PDFBOX-2361.
-----------------------------------
    Resolution: Not a Problem

> Blank pages after conversion images to pdf
> ------------------------------------------
>
>                 Key: PDFBOX-2361
>                 URL: https://issues.apache.org/jira/browse/PDFBOX-2361
>             Project: PDFBox
>          Issue Type: Bug
>    Affects Versions: 1.8.4
>            Reporter: Oleksandr Dronyk
>
> I am trying to convert images (png, jpg) to pdf and the issue is that after conversion document pages are blank.
> Used code:
> {code:borderStyle=solid}
>         PDDocument doc = new PDDocument();
>         for (BufferedImage buff : list) {
>             PDPage page = new PDPage(new PDRectangle(buff.getWidth(), buff.getHeight()));
>             doc.addPage(page);
>             PDXObjectImage ximage = new PDJpeg(doc, buff);
>             PDPageContentStream content = new PDPageContentStream(doc, page);
>             content.drawImage(ximage, 0, 0);
>             content.close();
>         }
>         doc.save(outStream);
>         doc.close();
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)