Bug 14619

Summary: Poppler-cairo not displaying pdf correctly
Product: poppler Reporter: Pedro Villavicencio <pvillavi>
Component: cairo backendAssignee: poppler-bugs <poppler-bugs>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: medium CC: mpsuzuki
Version: unspecified   
Hardware: x86 (IA32)   
OS: All   
Whiteboard:
i915 platform: i915 features:
Bug Depends on: 27456    
Bug Blocks:    
Attachments: Fix-test-for-rotation.patch

Description Pedro Villavicencio 2008-02-22 03:49:44 UTC
This report has been filed here:

https://bugs.launchpad.net/ubuntu/+source/poppler/+bug/193927

"Evince does not display a pdf correctly. It seems like a layer or something is missing.
I have no idea of how the pdf was made but I have attached the example.pdf to this bug report. I will also attach screenshots from evince and also xpdf (which does display it correctly)."

http://launchpadlibrarian.net/12128520/example.pdf
http://launchpadlibrarian.net/12128526/evince.png
http://launchpadlibrarian.net/12128527/xpdf.png

Thanks,
Comment 1 Albert Astals Cid 2008-02-22 14:31:10 UTC
Can reproduce it on cairo backend, not with splash
Comment 2 Carlos Garcia Campos 2009-11-18 09:06:52 UTC
This is another bug in drawImageMaskPrescaled :-(
Comment 3 Patrick 2012-01-19 06:32:54 UTC
Created attachment 55785 [details] [review]
Fix-test-for-rotation.patch

This patch fixes the bug, which stems from the wrong assumption
that rotation can be detected by testing (matrix.xy == 0 && matrix.yx == 0) only.

Defined LOG_CAIRO in CairoOutputDev.cc and checked the output to
make sure the test works, with the old attached pdf: Edited it in vim and changed /Rotate 180 to 0, 90 and 270 ("attempting to reconstruct xref table" succeeded...). Prints "drawImageMaskPrescaled" if the mask is not rotated, and "drawImageMask" if it is, as intended.
Comment 4 Carlos Garcia Campos 2012-01-20 06:37:19 UTC
Comment on attachment 55785 [details] [review]
Fix-test-for-rotation.patch

Review of attachment 55785 [details] [review]:
-----------------------------------------------------------------

Pushed to git master, thanks!

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.