[poppler] [Poppler-bugs] [Bug 22473]

Albert Astals Cid aacid at kde.org
Fri Jun 26 14:47:56 PDT 2009

Moving to the poppler list

A Divendres, 26 de juny de 2009, James Cloos va escriure:
> Albert> Well i did it by empirical testing, get the pdf remove the
> Albert> /Matte[0 0 0] entry of the object 51 and see how the left "More
> Albert> Text Here TBD" in Adobe Acrobat is rendered with the exact same
> Albert> color we get in poppler.
> Interesting.

Yep, looking at the formula for Matte color calculation it seems that Matte 0 
0 0 should not affect rendering at all, Leonard can you shed some light here?

> Last night, working w/o any lights on, I was unable to discern any
> difference at all between the two windows in the png.
> Now that the sun is up, albeit still w/o any interior lighting, the
> difference is easy to see.
> Isn't colour fun?!

Tell me... (i've Deuteranopia)

> The reply was, of course, supposed to go to bugz-d rather than the
> list.  But since it was wrong, I'm not going to correct that....


> So, to handle Matte, the ref says the SMask's Width and Height have to
> match the primary image's, so Matte should probably be checked for
> earlier in the code than were the Matte comment is in Gfx.cc.

What the spec doesn't say is what one should do if they are not the same :-/

> Should OutputDev::drawSoftMaskedImage() get another arg to pass the
> Matte array?  Or should it be added to the GfxImageColorMap object?

C++ way is having GfxSoftMaskImageColorMap subclassing GfxImageColorMap that 
adds the Matte entry.


> Either way, it looks like dealing with it will certainly complicate
> CairoOutputDev::drawSoftMaskedImage(), since it won't be able to use
> cairo_mask() when there is a Matte array....
> -JimC

More information about the poppler mailing list