gdk_pixbuf_composite() issue



I've got a pixbuf, created with gdk_pixbuf_new() (let's call it combined_pixbufs), with a width/height large enough to accommodate two pixbufs side-by-side. I then have two smaller pixbufs: pixbuf_one and pixbuf_two. I'm trying to use gdk_pixbuf_composite() to combine them side-by-side into combined_pixbufs:

x = 0, y = 0;
gdk_pixbuf_composite(pixbuf_one, combined_pixbufs, x, y, pixbuf_one_width, pixbuf_one_height, 0.0, 0.0, 1.0, 1.0, GDK_INTERP_BILINEAR, 255);
x += pixbuf_one_width;
gdk_pixbuf_composite(pixbuf_two, combined_pixbufs, x, y, pixbuf_two_width, pixbuf_two_height, 0.0, 0.0, 1.0, 1.0, GDK_INTERP_BILINEAR, 255);

The first pixbuf shows up in combined_pixbufs perfectly. The second one is all blurry and stretched. I can change the call with pixbuf_two to pixbuf_one (so it copies pixbuf_one twice), and the second time it's copied it shows up stretched and blurry, but not the first time.

Anyone know why this is, or an easier way to combine pixbufs together?



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