Synopsis#include <gdk-pixbuf/gdk-pixbuf.h> GdkPixbuf* gdk_pixbuf_xlib_get_from_drawable (GdkPixbuf *dest, Drawable src, Colormap cmap, Visual *visual, int src_x, int src_y, int dest_x, int dest_y, int width, int height); DescriptionThe functions in this section allow you to take the image data from an X drawable and dump it into a GdkPixbuf. This can be used for screenshots and other special effects. Note that these operations can be expensive, since the image data has to be transferred from the X server to the client program and converted. These functions are analogous to those for the GDK version of gdk-pixbuf. Detailsgdk_pixbuf_xlib_get_from_drawable ()GdkPixbuf* gdk_pixbuf_xlib_get_from_drawable (GdkPixbuf *dest, Drawable src, Colormap cmap, Visual *visual, int src_x, int src_y, int dest_x, int dest_y, int width, int height); Transfers image data from a Gdk drawable and converts it to an RGB(A) representation inside a GdkPixbuf.
If the drawable
If the specified destination pixbuf If the specified drawable is a pixmap, then the requested source rectangle must be completely contained within the pixmap, otherwise the function will return NULL. If the specified drawable is a window, then it must be viewable, i.e. all of its ancestors up to the root window must be mapped. Also, the specified source rectangle must be completely contained within the window and within the screen. If regions of the window are obscured by noninferior windows, the contents of those regions are undefined. The contents of regions obscured by inferior windows of a different depth than that of the source window will also be undefined.
|