[
https://issues.apache.org/jira/browse/FOP-3171?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17829852#comment-17829852
]
Simon Steiner edited comment on FOP-3171 at 3/22/24 12:11 PM:
--------------------------------------------------------------
What about adding into the fop.xconf:
<image-loading>
<penalty value="2000"
class="org.apache.xmlgraphics.image.loader.impl.PreloaderRawPNG"/>
<penalty value="2000"
class="org.apache.xmlgraphics.image.loader.impl.ImageLoaderRawPNG"/>
</image-loading>
was (Author: ssteiner1):
What about adding into the fop.xconf:
<image-loading>
<penalty value="-1000"
class="org.apache.xmlgraphics.image.loader.impl.PreloaderRawPNG"/>
<penalty value="-1000"
class="org.apache.xmlgraphics.image.loader.impl.ImageLoaderRawPNG"/>
<penalty value="1000"
class="org.apache.xmlgraphics.image.loader.impl.ImageLoaderPNG"/>
<penalty value="1000"
class="org.apache.xmlgraphics.image.loader.impl.imageio.ImageLoaderImageIO"/>
</image-loading>
> Certain PNG images (grayscale, transparent) produce broken PDF
> --------------------------------------------------------------
>
> Key: FOP-3171
> URL: https://issues.apache.org/jira/browse/FOP-3171
> Project: FOP
> Issue Type: Bug
> Components: image/png
> Affects Versions: 2.8
> Reporter: Martin Leitner
> Priority: Major
> Attachments: document.fo, fop_2.6_ok.pdf, fop_2.7_ok.pdf,
> fop_2.8_nok.pdf, fop_2.9_nok.pdf, number.png
>
>
> Rendering the attached document, which references the also attached image,
> produces a broken PDF in version 2.8 and 2.9. Depending on the PDF viewer,
> the image is distorted, or is shown with a large black bar at the bottom, or
> is shown three times, or is not shown at all. In some viewers, the content
> following the image is not shown.
> Up until version 2.7 the resulting PDF was fine. Generated PDFs are attached.
> The image in question was auto-generated by a customer. If this cannot be
> fixed easily, it may help to know what property of the image causes the
> problem for finding a workaround.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)