Re: simple example of using gdk_pixbuf_new_from_file

On 5/31/05, Freddie Unpenstein <fredderic excite com> wrote:

You mean all overlapping each other? You can only display a single "flat" 
image (animations not counted). So if they're one ontop of another, you need 
to composit them together into a single image.

The preferred monster, is;

void gdk_draw_pixbuf (GdkDrawable *drawable, GdkGC *gc, GdkPixbuf *pixbuf, 
gint src_x, gint src_y, gint dest_x, gint dest_y, gint width, gint height, 
GdkRgbDither dither, gint x_dither, gint y_dither);

... or, if you don't mind using depreciated functions ...

void gdk_pixbuf_render_to_drawable_alpha (GdkPixbuf *pixbuf, GdkDrawable 
*drawable, int src_x, int src_y, int dest_x, int dest_y, int width, int 
height, GdkPixbufAlphaMode alpha_mode, int alpha_threshold, GdkRgbDither 
dither, int x_dither, int y_dither);

(I didn't actually know the latter had been depreciated... Seems they've 
ditched the alpha_mode and alpha_threshold, and added a gc instead.)

That's basically your main tool. Composit them all together, probably into 
a new image of the appropriate size (unless you don't mind trashing the one 
at the bottom of the heap) and stick the result into a GtkImage or 


Can you do me favour ?
Please mail me a complete code for composting images.
Thanks in Advance

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