Mathias Hasselmann

Postings by Mathias on November 24, 2008

Blur Effect with cairo

Wondered how to apply convolution filters, like for instance gaussian blur in cairo. Doesn't seem to be possible yet. Well, unless you remember that cairo uses pixman as backend for its image surface. Result of my hacks below:

Blur Effect with cairo

The code is in the blur_image_surface() function of blur-effect.c. Now the question is how to make a nice cairo API for this code, and how to hardware accelerate this. At least XRender seems to define API for convolution filters.

Update: Get full code via git clone http://taschenorakel.de/git/playground