pdfbox-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Tilman Hausherr <THaush...@t-online.de>
Subject Re: Error on PDFRenderer.renderImage (PDFBox 2.0)
Date Sun, 01 Feb 2015 15:06:24 GMT
No good news - I extracted the JPEG file with NOTEPAD++ and get the same 
error with ImageIO.

What does work is
JPEGImageDecoder imageDecoder = JPEGCodec.createJPEGDecoder(...);
raster = imageDecoder.decodeAsRaster();

but then the colors are black and violet :-(

Tilman


Am 30.01.2015 um 12:00 schrieb Kevin Morin:
> Hi,
>
> I have the following error when I try to render a PDF file (I cannot 
> send it on a plublic list, but I can send it in private if needed). It 
> happens with PdfBox 2.0 under Linux and Windows, Java 7 but not Java 8.
>
> Invalid image format
>     sun.java2d.cmm.kcms.CMM.checkStatus(CMM.java:180)
>     sun.java2d.cmm.kcms.CMM.createTransform(CMM.java:134)
>     java.awt.image.ColorConvertOp.filter(ColorConvertOp.java:540)
>
> com.sun.imageio.plugins.jpeg.JPEGImageReader.acceptPixels(JPEGImageReader.java:1263)

>
>     com.sun.imageio.plugins.jpeg.JPEGImageReader.readImage(Native Method)
>
> com.sun.imageio.plugins.jpeg.JPEGImageReader.readInternal(JPEGImageReader.java:1231)

>
>
> com.sun.imageio.plugins.jpeg.JPEGImageReader.read(JPEGImageReader.java:1034) 
>
>     javax.imageio.ImageReader.read(ImageReader.java:940)
>     org.apache.pdfbox.filter.DCTFilter.decode(DCTFilter.java:72)
> org.apache.pdfbox.cos.COSStream.attemptDecode(COSStream.java:463)
>     org.apache.pdfbox.cos.COSStream.doDecode(COSStream.java:417)
>     org.apache.pdfbox.cos.COSStream.doDecode(COSStream.java:363)
> org.apache.pdfbox.cos.COSStream.getDecodeResult(COSStream.java:303)
>
> org.apache.pdfbox.pdmodel.graphics.image.PDImageXObject.<init>(PDImageXObject.java:115)

>
>
> org.apache.pdfbox.pdmodel.graphics.PDXObject.createXObject(PDXObject.java:65) 
>
> org.apache.pdfbox.pdmodel.PDResources.getXObject(PDResources.java:193)
>
> org.apache.pdfbox.contentstream.operator.graphics.DrawObject.process(DrawObject.java:42)

>
>
> org.apache.pdfbox.contentstream.PDFStreamEngine.processOperator(PDFStreamEngine.java:803)

>
>
> org.apache.pdfbox.contentstream.PDFStreamEngine.processStreamOperators(PDFStreamEngine.java:465)

>
>
> org.apache.pdfbox.contentstream.PDFStreamEngine.processStream(PDFStreamEngine.java:439)

>
>
> org.apache.pdfbox.contentstream.PDFStreamEngine.processPage(PDFStreamEngine.java:149)

>
> org.apache.pdfbox.rendering.PageDrawer.drawPage(PageDrawer.java:163)
>
> org.apache.pdfbox.rendering.PDFRenderer.renderPage(PDFRenderer.java:204)
>
> org.apache.pdfbox.rendering.PDFRenderer.renderImage(PDFRenderer.java:137)
>
> org.apache.pdfbox.rendering.PDFRenderer.renderImage(PDFRenderer.java:70)
>
> Thanks for your help
> Best
>
> Kevin
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@pdfbox.apache.org
> For additional commands, e-mail: users-help@pdfbox.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@pdfbox.apache.org
For additional commands, e-mail: users-help@pdfbox.apache.org


Mime
View raw message