Bug 13432 - no output
Summary: no output
Status: RESOLVED FIXED
Alias: None
Product: cairo
Classification: Unclassified
Component: general (show other bugs)
Version: 1.5.2
Hardware: Other All
: medium normal
Assignee: Carl Worth
QA Contact: cairo-bugs mailing list
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-11-28 13:22 UTC by Charles Doutriaux
Modified: 2008-01-05 19:27 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments
code showing the bug 1.4 vs 1.5 (79.95 KB, application/octet-stream)
2007-11-28 13:23 UTC, Charles Doutriaux
Details
sample of bad/empty ps file (458 bytes, application/postscript)
2007-11-28 13:24 UTC, Charles Doutriaux
Details
sample of good/working ps file (linked against 1.4.12) (50.34 KB, application/postscript)
2007-11-28 13:25 UTC, Charles Doutriaux
Details

Description Charles Doutriaux 2007-11-28 13:22:30 UTC
I'm attaching a code that produces output if linked to cairo.1.4.12 and nothing if ran under 1.5.2. In the example it produces a postscript, but the problem happens with pdf or png as well. Not sure what "triggers" cairo to go to "bitmap" mode under the postscript, but it takes much longer and comes back empty!
Sorry I tried to make the code as small as possible but it does not "triggers" on the simple easy test case i made so far. I keep trying though.

I'm using Linux 2.6, but i'm sure i can reproduce it under Mac OS X (10.4)
Comment 1 Charles Doutriaux 2007-11-28 13:23:55 UTC
Created attachment 12796 [details]
code showing the bug 1.4 vs 1.5

linknig against 1.4 createsa valid postscript, linkning vs 1.5 creates an empty ps
Comment 2 Charles Doutriaux 2007-11-28 13:24:38 UTC
Created attachment 12797 [details]
sample of bad/empty ps file
Comment 3 Charles Doutriaux 2007-11-28 13:25:26 UTC
Created attachment 12798 [details]
sample of good/working ps file (linked against 1.4.12)
Comment 4 Adrian Johnson 2007-12-02 02:24:41 UTC
I would recommend checking the error status using cairo_status() after the call to cairo_surface_finish(). Often when a bad or empty PostScript file is created cairo_status() will return an error code.

Running gdb on the test case I can see that in the analysis surface _cairo_traps_extents() is returning large numbers (x = 32767, y = 32767, width = 1, height = 1). There does not appear to be anything in your code that would make the coordinates go out of range.
Comment 5 Charles Doutriaux 2007-12-11 13:09:17 UTC
I noticed that in order to get my postscript output correct, i need to define the page as 600x600, then rotate and translate... if i declare the page as 600x790 for example then nothing is ever drawn. I'm thinking that mught be the problem with 1.5.2 that triggers "bitmap" mode for some reason and sees the bitmap as "out" of the page therefore not drawing it?

If that's so, any idea on how to fix the code to get the postscript in landscape mode?

Thx,

C.
Comment 6 Adrian Johnson 2008-01-05 19:27:18 UTC
Chris Wilson fixed the bug with this commit

http://gitweb.freedesktop.org/?p=cairo;a=commit;h=481fd3b4c8d3972ce21399f81b2021a57ed58f00

The test case now works for me.


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.