[Cairo] AA-Artifacts during/after gameoflife
Christof Petig
christof at petig-baender.de
Tue Nov 18 10:10:49 PST 2003
Carl Worth schrieb:
> On Nov 18, Christof Petig wrote:
> > I don't know whether the artifacts of 'gameoflife -c 20 -r 20 -p' are
> > possible to eliminate by a reasonable amount of work but they confused
> > me a bit (unless I realized that they are AA leftovers).
>
> Looks like just an application bug. I don't see any problem in cairo
> itself.
I thought that drawing a red Circle on white, then a white circle of
same size and then a black circle should ideally give the same result as
drawing only a black circle (but with AA it doesn't). And this was the
problem I suspected - clearing the canvas between game of life cycles is
cheating IMHO. [Though it will probably good enough for most applications.]
But perhaps repeatedly drawing the same text (or the same line) should
not darken the corners further. Possible with cairo?
> > Keep up the good work, I can hardly wait for a cairo based gtk+.
>
> Thank you. As for a "cairo based gtk+" you hardly need wait. In CVS,
> the cairo-demo/gtk directory shows you how to draw your own widgets
> using cairo. And the cairo-gtk-engine directory gives you a way to
> make Gtk+ use cairo for drawing all of its core widgets.
>
> I can't imagine that there is a lot still missing for a cairo based
> gtk+.
What about semi transparent widgets? I was under the impression that
this needs a client side rendering library for gdk (which is what cairo
can do). Semi transparent toplevel windows are a different problem
(solved by keith's X server) but the current gdk implementation uses a
lot of subwindows (which might also get semitransparent under said
server without needing cairo?).
All in all I was told (on gtk-devel) that semitransparent widgets need
cairo. Imagine an semitransparent entry widget on top of an image -
looks really cool and since I have first seen it in my wife's tax return
program (Windows 95 and up) I have longed to do such a thing myself (gtk).
Christof
More information about the cairo
mailing list