[
https://issues.apache.org/jira/browse/PDFBOX-3897?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16127581#comment-16127581
]
ASF subversion and git services commented on PDFBOX-3897:
---------------------------------------------------------
Commit 1805108 from [~tilman] in branch 'pdfbox/branches/2.0'
[ https://svn.apache.org/r1805108 ]
PDFBOX-3897: rev 1763808 no longer works on jdk9, try different attempt
> Avoid sRGB self-conversions
> ---------------------------
>
> Key: PDFBOX-3897
> URL: https://issues.apache.org/jira/browse/PDFBOX-3897
> Project: PDFBox
> Issue Type: Improvement
> Components: Rendering
> Affects Versions: 2.0.7
> Reporter: Tilman Hausherr
> Assignee: Tilman Hausherr
> Labels: optimization
> Fix For: 2.0.8, 3.0.0
>
> Attachments: PDFJS-6737-veryslow.pdf, PDFJS-8446-p1-slow.pdf
>
>
> 1)
> PDICCBased.java detects if the colorspace is sRGB, but does not use this
> advantage fully. {{toRGB()}} should return its argument when the colorspace
> is sRGB.
> The files from PDF.js issues 8446 and 6737 are much faster now. The speed
> improvement can be experienced with files that use such pseudo ICC
> colorspaces for shading, because there a large number of colors have to be
> converted.
> 2)
> PDDeviceRGB.java also converts colors to itself. {{awtColorSpace}} is the
> sRGB color space and so is {{/DeviceRGB}}, yet {{toRGB()}} calls
> {{awtColorSpace.toRGB()}} instead of just returning its argument.
> This second change does not have much influence on the speed of rendering on
> my old computer (4 cores). But on the new computer (8 cores, 16 threads) the
> complete rendering tests are now done in 300 instead of 400 seconds.
> Rendering regression tests show a lot of small differences. I assume that
> differences of 1/255 in a color somehow propagate and worsen, e.g. through
> transparency layers. I looked at a few, the differences are detected by the
> rendering tests but are invisible to my eye (in the diff file, the difference
> can be made visible by setting Gamma to minimum). I've therefore increased
> the tolerance to 3 units to avoid the work of analyzing hundreds of file
> differences. Those that remain are still invisible to my eye, except
> PDFBOX-3693-656282-p1-p8.pdf, which is very different but was different than
> Adobe before (the whole file is very broken and the first page logs over 3000
> errors). I suspect it is an incorrect RGB value that isn't clipped anymore
> now.
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]