On 8/9/05, Boncek, John <[EMAIL PROTECTED]> wrote: > I have a GdkPixmap. I need to programmatically extract a new GdkPixmap > from this image based on x- and y-coordinates, plus width and height. The > x, y, width, and height parameters will vary too much at runtime to store > all the copies needed.
I think you just make a new small pixmap of the size you need, then copy the pixels you want from your big pixmap into the small pixmap. The copy will (usually) be done in hardware, so it's very fast. You could consider using a pixbuf instead and doing the manipluation on the client side, but perhaps that doesn't suit your application. If it does, there's a very convenient pixbuf constructor: http://developer.gnome.org/doc/API/2.0/gdk-pixbuf/gdk-pixbuf-creating.html#gdk-pixbuf-new-subpixbuf John _______________________________________________ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list