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 2016/12/27 16:06:58 UTC

[jira] [Comment Edited] (PDFBOX-3640) java.awt.geom.NoninvertibleTransformException: Determinant is -0.0

    [ https://issues.apache.org/jira/browse/PDFBOX-3640?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15780685#comment-15780685 ] 

Tilman Hausherr edited comment on PDFBOX-3640 at 12/27/16 4:06 PM:
-------------------------------------------------------------------

Your file has this in page 1 at {{Root/Pages/Kids/[0]/Kids/[0]/Contents/[7]}}:
{code}
q
0 g
0 0 95.5444 -211.7696 480.23346 474.70703 cm
BX
/Sh15 sh
EX
Q
{code}
The 0 0 creates a matrix that has a scale and a shear of 0. That can't be good. I'm now using a default in case of error and the file renders (although not as good as Adobe). The error you posted is non fatal, it is the NPE coming after that that is fatal. The error will still be posted, now with an extra detail.


was (Author: tilman):
Your file has this in page 1 at {{Root/Pages/Kids/[0]/Kids/[0]/Contents/[7]}}:
{code}
q
0 g
0 0 95.5444 -211.7696 480.23346 474.70703 cm
BX
/Sh15 sh
EX
Q
{code}
The 0 0 creates a matrix that has a scale and a shear of 0. That's can't be good. I'm now using a default in case of error and the file renders (although not as good as Adobe). The error you posted is non fatal, it is the NPE coming after that that is fatal. The error will still be posted, now with an extra detail.

> java.awt.geom.NoninvertibleTransformException: Determinant is -0.0
> ------------------------------------------------------------------
>
>                 Key: PDFBOX-3640
>                 URL: https://issues.apache.org/jira/browse/PDFBOX-3640
>             Project: PDFBox
>          Issue Type: Bug
>    Affects Versions: 2.0.4
>            Reporter: Marco Silva
>              Labels: shading
>         Attachments: E-book_22-boas-praticas-de-comunicacao-interna.pdf
>
>
> I have this error trying to parse a specific PDF file:
> {code}
> o.a.p.p.g.s.AxialShadingContext [AxialShadingContext.java:115] ERROR - java.awt.geom.NoninvertibleTransformException: Determinant is -0.0
>  java.awt.geom.NoninvertibleTransformException: Determinant is -0.0
>         at java.awt.geom.AffineTransform.createInverse(AffineTransform.java:2668)
>         at org.apache.pdfbox.pdmodel.graphics.shading.AxialShadingContext.<init>(AxialShadingContext.java:110)
>         at org.apache.pdfbox.pdmodel.graphics.shading.AxialShadingPaint.createContext(AxialShadingPaint.java:67)
>         at sun.java2d.pipe.AlphaPaintPipe.startSequence(AlphaPaintPipe.java:84)
>         at sun.java2d.pipe.AAShapePipe.renderTiles(AAShapePipe.java:168)
>         at sun.java2d.pipe.AAShapePipe.renderPath(AAShapePipe.java:159)
>         at sun.java2d.pipe.AAShapePipe.fill(AAShapePipe.java:68)
>         at sun.java2d.pipe.PixelToParallelogramConverter.fill(PixelToParallelogramConverter.java:164)
>         at sun.java2d.pipe.ValidatePipe.fill(ValidatePipe.java:160)
>         at sun.java2d.SunGraphics2D.fill(SunGraphics2D.java:2527)
>         at org.apache.pdfbox.rendering.PageDrawer.shadingFill(PageDrawer.java:921)
>         at org.apache.pdfbox.contentstream.operator.graphics.ShadingFill.process(ShadingFill.java:41)
>         at org.apache.pdfbox.contentstream.PDFStreamEngine.processOperator(PDFStreamEngine.java:815)
>         at org.apache.pdfbox.contentstream.PDFStreamEngine.processStreamOperators(PDFStreamEngine.java:472)
>         at org.apache.pdfbox.contentstream.PDFStreamEngine.processStream(PDFStreamEngine.java:446)
>         at org.apache.pdfbox.contentstream.PDFStreamEngine.processPage(PDFStreamEngine.java:149)
>         at org.apache.pdfbox.rendering.PageDrawer.drawPage(PageDrawer.java:189)
>         at org.apache.pdfbox.rendering.PDFRenderer.renderPage(PDFRenderer.java:208)
>         at org.apache.pdfbox.rendering.PDFRenderer.renderImage(PDFRenderer.java:139)
> {code}



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

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