[cairo-bugs] [Bug 105294] New: pdftocairo -pdf inverts image color in this PDF

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Wed Feb 28 16:13:15 UTC 2018


            Bug ID: 105294
           Summary: pdftocairo -pdf inverts image color in this PDF
           Product: cairo
           Version: unspecified
          Hardware: Other
                OS: All
            Status: NEW
          Severity: normal
          Priority: medium
         Component: pdf backend
          Assignee: ajohnson at redneon.com
          Reporter: jason at inspiresomeone.us
        QA Contact: cairo-bugs at cairographics.org

Created attachment 137691
  --> https://bugs.freedesktop.org/attachment.cgi?id=137691&action=edit

I noticed this while verifying that
https://bugzilla.gnome.org/show_bug.cgi?id=757876 has been fixed in cairo. The
'missing spaces' problem is fixed, but I see a new issue now.

If I run `pdftocairo -pdf` on the attached PDF file, images in the output PDF
show reversed black and white. I traced it to this commit in cairo:

commit b207a932a2d3740984319dffd58a0791580597cd (HEAD, refs/bisect/bad)
Author: Peter TB Brett <peter.brett at livecode.com>
Date:   Fri Sep 9 22:35:55 2016 +0930

    Correctly decode Adobe CMYK JPEGs in PDF export

    Adobe PhotoShop generates CMYK JPEG files with inverted CMYK.  When a
    JPEG file with this format is included in a PDF file, a `/Decode`
    array must be included to convert to "normal" CMYK.

    These JPEG files can be detected via the presence of the APP14 "Adobe"
    marker.  However, PDF viewers are not required to detect and handle
    this private marker, so it must be detected and handled (by adding a
    `/Decode`) by the PDF generator.

    Signed-Off-By: Peter TB Brett <peter.brett at livecode.com>

You are receiving this mail because:
You are the QA Contact for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.cairographics.org/archives/cairo-bugs/attachments/20180228/2febe5e3/attachment.html>

More information about the cairo-bugs mailing list