Bug 101699 - pdftocairo converted svg has inverted image mask for composition
Summary: pdftocairo converted svg has inverted image mask for composition
Status: RESOLVED DUPLICATE of bug 68965
Alias: None
Product: poppler
Classification: Unclassified
Component: cairo backend (show other bugs)
Version: unspecified
Hardware: Other All
: medium normal
Assignee: poppler-bugs
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-07-05 15:33 UTC by ksamarin
Modified: 2018-04-24 15:36 UTC (History)
2 users (show)

See Also:
i915 platform:
i915 features:


Attachments
Source pdf (1.17 MB, application/pdf)
2017-07-05 15:33 UTC, ksamarin
Details
Rendering result (942.18 KB, image/png)
2017-07-05 15:34 UTC, ksamarin
Details
out.svg (2.56 MB, image/svg+xml)
2017-07-06 13:00 UTC, Adrian Johnson
Details
out.png (518.98 KB, image/png)
2017-07-06 13:01 UTC, Adrian Johnson
Details
PDF with images whose colors become inverted (121.40 KB, application/pdf)
2018-03-15 00:29 UTC, Allan Haldane
Details

Description ksamarin 2017-07-05 15:33:51 UTC
Created attachment 132457 [details]
Source pdf

After conversion
pdftocairo -svg -f 1 -l 1 -nocrop PTLID084991.pdf PTLID084991.pdf.svg the result svg has inverted mask in the middle of svg. (Ubuntu 14.04 file viewer used to check)
Comment 1 ksamarin 2017-07-05 15:34:56 UTC
Created attachment 132458 [details]
Rendering result
Comment 2 Adrian Johnson 2017-07-05 22:01:52 UTC

*** This bug has been marked as a duplicate of bug 68965 ***
Comment 3 ksamarin 2017-07-06 12:41:20 UTC
(In reply to Adrian Johnson from comment #2)
> 
> *** This bug has been marked as a duplicate of bug 68965 ***

Sorry Adrian, but this does not look like a duplicate to me.
- the patch has been included in the sources from which pdftocairo was compiled. (I have rechecked this.)
- the patch updated _cairo_surface_base64_encode_jpeg function but provided image in the svg responsible for inverted mask is a PNG file with RGBA colorspace.

So why do you think this is a duplicate?
Comment 4 Adrian Johnson 2017-07-06 12:59:14 UTC
Maybe it is not bug 68965. I duped it because the conversion works for me and the bug description sounded the same.

I'll attach the output I get using poppler git and cairo git.
Comment 5 Adrian Johnson 2017-07-06 13:00:22 UTC
Created attachment 132479 [details]
out.svg

The SVG output.
Comment 6 Adrian Johnson 2017-07-06 13:01:01 UTC
Created attachment 132480 [details]
out.png

SVG output rendered with rsvg-convert.
Comment 7 Allan Haldane 2018-03-15 00:29:36 UTC
Created attachment 138119 [details]
PDF with images whose colors become inverted


I am seeing probably the same thing, with poppler 0.61.1-1, cairo 1.15.10-1, except that I also get it for pdf output (see attached pdf)

$ pdftocairo page17.pdf -pdf out.pdf

See how the image in page17.pdf becomes inverted in out.pdf?

This affects about half of the pdfs I print using evince, since evince seems to pass all pdfs though this command before sending them to the printer. My workaround has been to use okular or lpr to print, which do not suffer this problem.

I don't think this is a duplicate.
Comment 8 Allan Haldane 2018-03-15 15:00:01 UTC
Never mind, my issue is this one: https://bugs.freedesktop.org/show_bug.cgi?id=105294


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.