[cairo] cairo internal design ideas
Ross McFarland
rwmcfa1 at neces.com
Wed Sep 22 15:30:11 PDT 2004
On Wed, 2004-09-22 at 15:52, Jost Boekemeier wrote:
> Hi,
>
> I think we can leave out the font/glyph problem, which
> is a completely different issue.
>
> > Hence, supporting
> > higher level output devices like PS, PDF and SVG in
> > a good way
>
> Can you please explain this? At least for PDF and SVG
> it is not a problem to render trapezoids. If you are
> concerned about the document size, just compress the
> streams. -- I have to say that I have experience only
> with postscript which does not support alpha.
the two (and a half) problems i ran into when doing the pdf back-end
were:
1/2) file size, sure it will compress, but that doesn't change the fact
that it's bigger than it could and should be. documents could easily be
10x the size, even with compression (the draws for each of the traps
aren't going to compress much.) that doesn't matter much when you're
talking about a single page pdf, but if you were to do a 250 page
document it would be quickly become unacceptable.
1) drawing speed. when lots and lots of little draws many of the pdf
back-ends draw slow enough that you can watch it draw (though it's still
pretty fast.) this would start to matter when you talk about viewing
them on embedded devices (cell phones, pda's, etc.) printers would be
another place where this would matter quite a bit. pdf's with 1000's of
draws could drastically reduce print speed.
2) drawing bugs. when you mix alpha with breaking up areas of a fill you
get slight overlaps that mess up the alpha math. take a look at
http://www.neces.com/tmp/basket.pdf with a pdf reader that supports
alpha and you'll see what i mean. i won't say that it's impossible to
prevent this problem, but it's not trivial anyway and i don't see a
solution. it would greatly complicate the back-end. you'd have to keep
track of all of the pieces and make absolutely sure that they didn't get
drawn overlapping (likely would vary viewer to viewer) no matter the
view resolution.
--
-rm
http://www.neces.com/
More information about the cairo
mailing list