[cairo] PS backend

Keith Packard keithp at keithp.com
Wed May 5 10:15:25 PDT 2004


Around 17 o'clock on May 5, "Rob Taylor" wrote:

> i'm going to have to hook into the cairo API at a much higher level than
> current backends (the same will go for a decent PDF backend to, i
> suppose). So I suppose my question is, 1) is there agreement on this, and
> 2) where should i put the indirection? I'm currently trying to decide
> whether i should put it in at api level (in cairo.c) or if i could reuse
> some of the functionality of gstate.. I wont know really till I've done a
> bit more research, but if anyone has any input, I'd be glad to hear it :)

PS doesn't support the whole cairo drawing model, and it has some serious 
precision problems in drawing objects, so we want to hook lower than you 
might at first think.  For geomtery, we really want cairo to compute 
trapezoids and send those to the output device instead of sending the high 
level paths.

The hardest part for all of this will be catching regions of the output 
which cannot be drawn with PS commands and drawing them in memory.  I 
suggest that this might actually be more easily accomplished by rendering 
the output to some kind of meta file and then converting that to PS in a 
secondary pass.  It might be that the right format for this is PDF 1.4; 
that can be converted to PS with existing tools, moving us from two 
separate backends to a single backend...

-keith


-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 228 bytes
Desc: not available
Url : http://lists.freedesktop.org/archives/cairo/attachments/20040505/3e110687/attachment.pgp


More information about the cairo mailing list