[cairo] New OpenGL backend merged

Jonathan Morton jonathan.morton at movial.com
Thu Jul 23 02:43:30 PDT 2009


> One thing I have noticed about OpenGL is that it seems to be difficult to
> achieve good antialiasing because this appears to be under the control of
> the graphics driver and therefore the end user can turn it on or off.  Does
> using an OpenGL back-end for Cairo mean that it will also suffer from this
> problem?  Or is there a way to force antialiasing on at all times when using
> OpenGL?

As a gross simplification, Cairo performs two kinds of operation:
rasterising and compositing.

Rasterising is where the antialiasing happens, as the paths are turned
into pixels.  This can be done on the CPU without excessive difficulty,
since it is roughly O(paths*scanlines) rather than O(paths*pixels).

Compositing is difficult for a general-purpose CPU to do efficiently,
but is precisely what a GPU is good at.  This is simply pushing pixels
around, and the antialiasing settings on the GPU are largely irrelevant.
Indeed, some quite old GPUs (the first Radeons, for example) can be used
to good effect.

Unless I'm being unduly pessimistic, I would guess that OpenGL is used
for compositing and not rasterising at present.

-- 
------
From: Jonathan Morton
      jonathan.morton at movial.com




More information about the cairo mailing list