[
https://issues.apache.org/jira/browse/PDFBOX-5134?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17305421#comment-17305421
]
Tilman Hausherr edited comment on PDFBOX-5134 at 3/20/21, 1:05 PM:
-------------------------------------------------------------------
I tested your changes and had many invisible differences, and two slightly
visible (gs-bugzilla687307-2.pdf and PDFBOX-4217-shade_via_1.3_006.pdf). I got
rid of all of them except one (gs-bugzilla689095.pdf, differences are
invisible) with this code in the two context classes:
{code:java}
if (bounds != null)
{
bounds.add(new Point((int) Math.floor(bounds.getMinX())-1, (int)
Math.floor(bounds.getMinY())-1));
bounds.add(new Point((int) Math.ceil(bounds.getMaxX())+1, (int)
Math.ceil(bounds.getMaxY())+1));
} {code}
Another problem was that the rendering tests sometimes froze for a minute, then
went on. Apparently I got rid of that by calling {{dispose()}} on the context
after it's done.
was (Author: tilman):
I tested your changes and had many invisible differences, and two slightly
visible (gs-bugzilla687307-2.pdf and PDFBOX-4217-shade_via_1.3_006.pdf). I got
rid of most of them with this code in the two context classes:
{code:java}
if (bounds != null)
{
bounds.add(new Point((int) Math.floor(bounds.getMinX())-1, (int)
Math.floor(bounds.getMinY())-1));
bounds.add(new Point((int) Math.ceil(bounds.getMaxX())+1, (int)
Math.ceil(bounds.getMaxY())+1));
} {code}
Another problem was that the rendering tests sometimes froze for a minute, then
went on. Apparently I got rid of that by calling {{dispose()}} on the context
after it's done.
> Very slow rendering on PageDrawer.shadingFill
> ---------------------------------------------
>
> Key: PDFBOX-5134
> URL: https://issues.apache.org/jira/browse/PDFBOX-5134
> Project: PDFBox
> Issue Type: Bug
> Components: Rendering
> Affects Versions: 2.0.22, 2.0.23
> Reporter: Oliver Schmidtmer
> Priority: Major
> Labels: optimization, shading
> Attachments: PDFBOX-4217-shade_via_1.3_006.pdf,
> PDFBOX-4217-shade_via_1.3_006.pdf-1.png,
> PDFBOX-4217-shade_via_1.3_006.pdf-1.png-diff.png, Plan zum Testen.pdf,
> gs-bugzilla687307-2.pdf, gs-bugzilla687307-2.pdf-1.png,
> gs-bugzilla687307-2.pdf-1.png-diff.png, image-2021-03-17-20-16-49-221.png
>
>
> The PDF contains many effectively very small shadings, the light cones. As
> the gradient painting for each light cone is applied on the whole image,
> rendering is very slow: 29 of 33 seconds are spent in shadingFill.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]