[
https://issues.apache.org/jira/browse/PDFBOX-1094?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14242060#comment-14242060
]
John Hewson edited comment on PDFBOX-1094 at 12/11/14 3:08 AM:
---------------------------------------------------------------
{quote}
Additionally, I suspect that the best is not to try to extract the scale at
all, rather to do as much as possible by applying the transform to coordinates,
and calculate widths from the results.
{quote}
We can't transform the pattern beforehand, because TexturePaint requires the
pattern to be untransformed so that it can use an AffineMatrix to apply the
transform when doing the tiling. This is the only way to get diagonal tiling to
work, such as in PATTYP1.pdf.
We do however, transform the pattern, but only the scaling, because this
doesn't affect the tiling direction. This is needed to avoid blurry images in
cases where the pattern is scaled-up, or cases where the pattern is _giant_ and
is scaled-down.
It sounds like we need to be smarter about how the scaling is calculated, and
how to then calculate the appropriate AffineTransform to be used byTexturePaint.
was (Author: jahewson):
{quote}
Additionally, I suspect that the best is not to try to extract the scale at
all, rather to do as much as possible by applying the transform to coordinates,
and calculate widths from the results.
{quote}
We can't transform the pattern beforehand, because TexturePaint requires the
pattern to be untransformed so that it can use an AffineMatrix to apply the
transform when doing the tiling. This is the only way to get diagonal tiling to
work, such as in PATTYP1.pdf.
We do however, transform the pattern, but only the scaling, because this
doesn't affect the tiling direction. This is needed to avoid blurry images in
cases where the pattern is scaled-up, or cases where the pattern is *giant* and
is scaled-down.
It sounds like we need to be smarter about how the scaling is calculated, and
how to then calculate the appropriate AffineTransform to be used byTexturePaint.
> Pattern colorspace support
> --------------------------
>
> Key: PDFBOX-1094
> URL: https://issues.apache.org/jira/browse/PDFBOX-1094
> Project: PDFBox
> Issue Type: Improvement
> Components: Rendering
> Affects Versions: 1.6.0, 2.0.0
> Reporter: Andreas Lehmkühler
> Priority: Blocker
> Fix For: 2.0.0
>
> Attachments: ColoredTilingPaint.patch, PATTYP1.pdf, PATTYP2.pdf,
> PDF32000_2008_pg737.pdf, PDFBOX-1094-065514-XStep32767.pdf,
> PDFBOX-1094-094730.pdf, PDFBOX-1094-096213-p18.pdf,
> PDFBOX-1094-118358-Step-32767.pdf, PDFBOX-1094-PDFBOX-269.pdf,
> PDFBOX-1094-tiling_pattern.pdf-1-broken-tiles-with-ceil.png,
> PDFBOX-1861-tracemonkey13.png, PDFStreamEngine.patch, PageDrawer.patch,
> _pdfbox-1094-tiling_pattern.pdf-1-blurry.png, bugzilla8677511.jpg,
> gs-bugzilla688728.pdf, gs-bugzilla691715.pdf, gs-bugzilla692152.pdf,
> gs-bugzilla692503.ai, gs-bugzilla693653.pdf, gs-bugzilla694385.pdf,
> jagpdf_doc_patterns.pdf, jagpdf_doc_patterns.pdf-1.png,
> pdfbox-1094-pdf32000_2008_pg737.pdf-1.png,
> pdfbox-1094-pdf32000_2008_pg737.pdf-1.png, pdfbox-1094-pdfbox-269.pdf-2.png,
> pdfbox-1094-tiling_pattern.pdf-1.png, pdfbox-1094-tiling_pattern.pdf-1.png,
> pdfbox-1094-tiling_pattern.pdf-1.png, pdfbox-1861-tracemonkey.pdf-13.png,
> pdfbox-1861-tracemonkey.pdf-13.png, tiling_pattern.pdf,
> v2_tiling_patterns_v2.patch
>
>
> PDFBox doesn't support PDPattern colorspaces
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)