Re: canvas notes



On Sat, 2005-09-10 at 13:03 +1000, Russell Shaw wrote:
> Havoc Pennington wrote:
> > On Fri, 2005-09-09 at 09:53 +0200, Alexander Larsson wrote:
> > 
> >>* OpenGL
> > 
> > Any thoughts on that 3D vs. 2D thing? i.e. it seems like we want to be
> > able to mix OpenGL and Cairo at will, but it isn't clear to me what that
> > really means.
> > 
> > Kind of a similar question to is a compositing manager best done with
> > RENDER or GL as the foundation maybe...
> > 
> > Havoc
> 
> Why does cairo exist when everything can be done in OpenGL?
> All widgets and font rendering can be done with OpenGL too.

All programs that exist can be programmed on a universal turing machine.
That is interesting, but doesn't mean that people actually develop on
turing machines. OpenGL as an API is clearly targeted towards drawing of
3D scenes, and is not at all what you want when you're writing a
predominantly 2D graphical user interface, whereas Cairo is an ideal API
for this. (Additionally, cairo has other advantages like multiple
backends allowing it to print and export to files.)

Now, the fact that OpenGL can draw everything does make it potentially
interesting at some level of the rendering stack. In fact, there exist a
cairo backend that uses OpenGL. Of course, the current state of OpenGL
support on X/Linux is pretty weak wrt drivers and support for extensions
necessary for nice 2D work (like framebuffer objects or some other form
of render-to-texture), so in practice this is something that lies in the
future.

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
 Alexander Larsson                                            Red Hat, Inc 
                   alexl redhat com    alla lysator liu se 
He's a world-famous ninja cop with a winning smile and a way with the ladies. 
She's a cynical red-headed Valkyrie with a flame-thrower. They fight crime! 




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]