Bug 4140

Summary: clipping broken in image backend on powerpc
Product: cairo Reporter: Martin Kretzschmar <m_kretzschmar>
Component: image backendAssignee: Billy Biggs <billy.biggs>
Status: RESOLVED FIXED QA Contact: cairo-bugs mailing list <cairo-bugs>
Severity: normal    
Priority: high CC: cworth, krh
Version: 0.9.3   
Hardware: x86 (IA32)   
OS: Linux (All)   
Whiteboard:
i915 platform: i915 features:
Attachments: clip-nesting-image-out.png
clip-operator-image-out.png
clip-twice-image-out.png

Description Martin Kretzschmar 2005-08-19 11:52:47 UTC
The poppler cairo backend produces only blank pages (i.e. evince is unusable) on
powerpc if used with the image backend, it works fine with the xlib backend.

The first thing poppler does for each page is to clip to the paper area.
Removing that gives a non blank page.

I'll attach the (image backend) output of the clip-nesting, clip-operator and
clip-twice tests.
Comment 1 Martin Kretzschmar 2005-08-19 11:53:38 UTC
Created attachment 2931 [details]
clip-nesting-image-out.png
Comment 2 Martin Kretzschmar 2005-08-19 11:53:59 UTC
Created attachment 2932 [details]
clip-operator-image-out.png
Comment 3 Martin Kretzschmar 2005-08-19 11:54:21 UTC
Created attachment 2933 [details]
clip-twice-image-out.png
Comment 4 Owen Taylor 2005-08-19 12:32:33 UTC
If you aren't testing with Cairo CVS, can you test with Cairo CVS?
Comment 5 Martin Kretzschmar 2005-08-19 12:40:16 UTC
This was with a fresh CVS checkout.
Comment 6 Martin Kretzschmar 2005-08-19 12:42:28 UTC
Correction: the test files were generated with a fresh checkout.

I haven't tested poppler with this version of cairo.
Comment 7 Billy Biggs 2005-08-19 14:26:48 UTC
I get a bunch of failures on my Mac, although I don't think I've seen these
blank-image failures.
Comment 8 Martin Kretzschmar 2005-08-20 02:58:36 UTC
clip-nesting is not completely blank, some parts are white, some are transparent.

I didn't produce these on a Mac, but a G4 Pegasos II (shouldn't matter, I
guess). I'm using Ubuntu Breezy.

I looked at this problem after being notified of this:
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=315133

Does this pdf
http://bugs.debian.org/cgi-bin/bugreport.cgi/evince-test.pdf?bug=315133;msg=15;att=2
work on your Mac with evince and poppler using the cairo backend?

Can evince/poppler-cairo display pdfs at all on your Mac (since the debian bug
has been filed, a bug where poppler dropped all winding-rule clip operations has
been fixed, resulting in blank pages for every pdf file)?
Comment 9 Billy Biggs 2005-08-20 07:23:44 UTC
OK, we're seeing the same failures then, I think.
Comment 10 Billy Biggs 2005-08-20 21:30:57 UTC
Fixed in HEAD.

The problem was in pixman_fill_rect_8bpp.  It was converting the value of a 32
bit pixel to 8 bits like this:

    *(char*)pixel

When it really meant to do:

    (char) *pixel
Comment 11 Carl Worth 2005-08-22 17:14:29 UTC
Move bugs against "cvs" version to "0.9.3" so we can remove the "cvs" version.

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.