[cairo] PostScript backend now passes the entire test suite

Carl Worth cworth at cworth.org
Wed Dec 7 12:27:36 PST 2005


I just committed a fix so that the last failing test, (self-copy), now
works with the PostScript backend. This required implementing
_cairo_meta_surface_acquire_source_image by means of creating an image
surface and replaying to it. In order to do that, this function needed
access to a size for the surface, so I changed
_cairo_meta_surface_create to accept a size in pixels to be used for
this purpose.

This isn't the cleanest approach, (better would be to improve
the backend acquire_source_image interface to return only a region of
interest, but that gets complicated in light of surfaces used for
repeating patterns---plus it's more invasive than I want to be now).

Anyway, we've now finally got the PS backend passing the entire test
suite. It's currently back to using a giant image for each page, but
we have a bunch of code lying around that will do better than
that. All that really needs to be done is to start incrementally
turning that code on where it is known to work, (always ensuring that
the test suite continues to pass). The first step here would be to not
use the fallbacks at all if an entire page could be correctly rendered
without fallbacks. That much should be quite easy. With a bit more
work, the PS backend could start doing more minimal fallback regions.

So that's some good work that could be done my someone interested in
the quality of PS output from cairo.

Meanwhile, I'm going to switch my focus over to the PDF backend by
hooking it into the test suite (courtesy of poppler) and then
connecting it to the meta-surface code in a fashion similar to the PS
backend.

The native PDF output should be significantly more capable than the PS
output, so I'm hopeful that even with just a per-page switch of
fallbacks or not we can still get good PDF output for many cases.

-Carl

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://lists.freedesktop.org/archives/cairo/attachments/20051207/9a853a4d/attachment.pgp


More information about the cairo mailing list