Bug 52010 - Annotation is rendered with wrong color
Summary: Annotation is rendered with wrong color
Status: RESOLVED MOVED
Alias: None
Product: poppler
Classification: Unclassified
Component: general (show other bugs)
Version: unspecified
Hardware: Other All
: medium normal
Assignee: poppler-bugs
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-07-12 12:28 UTC by Fabio D'Urso
Modified: 2018-08-20 21:53 UTC (History)
2 users (show)

See Also:
i915 platform:
i915 features:


Attachments
Testcase (1.67 KB, application/pdf)
2012-07-12 12:28 UTC, Fabio D'Urso
Details
Simplified testcase (1017 bytes, application/x-pdf)
2012-08-23 17:27 UTC, Fabio D'Urso
Details

Description Fabio D'Urso 2012-07-12 12:28:56 UTC
Created attachment 64138 [details]
Testcase

In the attached file, the caret annotation is rendered yellow by poppler, but acroread renders it blue.
The annotation color (ie its /C property) is blue, but the appearance stream draws yellow. It seems that we ignore the blend mode (Difference), which should turn yellow into blue (they're complementary colors).

From https://bugs.kde.org/show_bug.cgi?id=300615
Comment 1 Fabio D'Urso 2012-08-23 17:27:26 UTC
Created attachment 66025 [details]
Simplified testcase

PDF document based on the first testcase

On the left side there's a yellow box drawn in blend-multiply mode. Since there's nothing in the background, it is correctly shown in yellow.
On the right side there's another yellow box drawn in blend-multiply mode, but this time it is contained in an annotation appearance stream. Poppler paints it yellow like the other one, acroread paints it blue.

In comparison with the original document, I've stripped the fields that do not affect this behavior. In particular I've noticed that this behavior does not depend on the annotation's properties and not even on its type: instead of a "Caret", in this document I used a "Circle" annotation.
Note that you see a box because that's what the appearance stream says, and annotation's type and properties are ignored during rendering if there's an appearance stream available like in this case.
Comment 2 Fabio D'Urso 2012-08-23 23:21:36 UTC
Oops. Sorry, it's blend mode difference, not multiply as I erroneously wrote in the previous comment. The attached file is sane.

Apart from this, I've found that acroread's output-to-ps feature also draws the annotation in yellow color. At the moment, I have no hardware to test what happens with a real printer.
It's kind of weird: the annotation is blue on screen, but yellow when printed to postscript.
Maybe we've hit an acroread bug, what do you think?

(acroread version 9.4.7 on Linux)
Comment 3 Albert Astals Cid 2012-08-24 17:42:55 UTC
Maybe someone can try on a newer acrobat on windows?
Comment 4 Thomas Freitag 2012-08-25 06:19:30 UTC
Same on WIndows with Acrobat Reader 10.1.4
If I use Acrobat Pro (also 10.1.4) and save it as EPS, the blue square disapears completely.
Comment 5 GitLab Migration User 2018-08-20 21:53:25 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/poppler/poppler/issues/111.


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.