Matthias Reischenbacher commented on FOP-2564:

Added a new version of the patch, which fixes s problem with Graphics2D output 
(e.g. SVG --> PDF). PDFGraphics2D.addRenderedImage re-creates a 
org.apache.xmlgraphics.image.loader.impl.ImageRendered instance, that can be 
handled by the ImageRenderedAdapter. This is not nice, because the image loader 
originally creates a org.apache.xmlgraphics.image.loader.impl.ImageRendered 
instance, which is then lost because 
ImageConverterBitmap2G2D.Graphics2DImagePainterImpl.paint() can only pass a 
java.awt.image.RenderedImage instance. This problem is also visible when 
PDFGraphics2D.addRenderedImage has to re-create the ImageInfo instance 
(ImageInfo info = new ImageInfo(null, "image/unknown")). In order to fix that, 
I wrap the org.apache.xmlgraphics.image.loader.impl.ImageRendered instance in a 
new class (ImageRenderedG2D) that implements the java.awt.image.RenderedImage 
interface and gives access to the original 
org.apache.xmlgraphics.image.loader.impl.ImageRendered instance.

> [PATCH] Ignore ICC profiles added by ImageIO loader
> ---------------------------------------------------
>                 Key: FOP-2564
>                 URL: https://issues.apache.org/jira/browse/FOP-2564
>             Project: FOP
>          Issue Type: Bug
>          Components: image/png
>            Reporter: Matthias Reischenbacher
>         Attachments: fop-2564-commons.patch, fop-2564.patch
> When rendering PNG files for PDF output, ICC profiles are taken into account 
> which were added by the ImageIO loader. This causes an unexpected color 
> display (light, dull colors) and should be avoided.
> This bug only applies to image files that don't have an embedded ICC profile 
> and are loaded by ImageLoaderImageIO.

This message was sent by Atlassian JIRA

Reply via email to