gtk-utils.c: Use cairo in show_image() rather than GdkPixbuf
authorSøren Sandmann Pedersen <ssp@redhat.com>
Fri, 15 Feb 2013 23:34:46 +0000 (18:34 -0500)
committerSøren Sandmann Pedersen <ssp@redhat.com>
Fri, 15 Feb 2013 23:57:24 +0000 (18:57 -0500)
commit2156fb51b353867d5a18b734690ca551f74d4fb1
treeeec42351119572dfab8f5947a1864945ce708350
parent5e207f825bd1ed3142a623bcbceca00508907c5e
gtk-utils.c: Use cairo in show_image() rather than GdkPixbuf

GdkPixbufs are not premultiplied, so when using them to display pixman
images, there is some unecessary conversions going on: First the image
is converted to non-premultiplied, and then GdkPixbuf premultiplies
before sending the result to the X server. These conversions may cause
the displayed image to not be exactly identical to the original.

This patch just uses a cairo image surface instead, which avoids these
conversions.

Also make the comment about sRGB a little more concise.
demos/gtk-utils.c