gdkDrawableGetImage          package:RGtk2          R Documentation

_g_d_k_D_r_a_w_a_b_l_e_G_e_t_I_m_a_g_e

_D_e_s_c_r_i_p_t_i_o_n:

     A 'GdkImage' stores client-side image data (pixels). In contrast,
     'GdkPixmap' and 'GdkWindow' are server-side objects.
     'gdkDrawableGetImage' obtains the pixels from a server-side
     drawable as a client-side 'GdkImage'.  The format of a 'GdkImage'
     depends on the 'GdkVisual' of the current display, which makes
     manipulating 'GdkImage' extremely difficult; therefore, in most
     cases you should use 'gdkPixbufGetFromDrawable' instead of this
     lower-level function. A 'GdkPixbuf' contains image data in a
     canonicalized RGB format, rather than a display-dependent format.
     Of course, there's a convenience vs. speed tradeoff here, so
     you'll want to think about what makes sense for your application.

_U_s_a_g_e:

     gdkDrawableGetImage(object, x, y, width, height)

_A_r_g_u_m_e_n_t_s:

'object': ['GdkDrawable']  a 'GdkDrawable'

     'x': [integer]  x coordinate on 'drawable'

     'y': [integer]  y coordinate on 'drawable'

 'width': [integer]  width of region to get

'height': [integer]  height or region to get

_D_e_t_a_i_l_s:

     'x', 'y', 'width', and 'height' define the region of 'drawable' to
     obtain as an image.

     You would usually copy image data to the client side if you intend
     to examine the values of individual pixels, for example to darken
     an image or add a red tint. It would be prohibitively slow to make
     a round-trip request to the windowing system for each pixel, so
     instead you get all of them at once, modify them, then copy them
     all back at once.

     If the X server or other windowing system backend is on the local
     machine, this function may use shared memory to avoid copying the
     image data.

     If the source drawable is a 'GdkWindow' and partially offscreen or
     obscured, then the obscured portions of the returned image will
     contain undefined data.

_V_a_l_u_e:

     ['GdkImage']  a 'GdkImage' containing the contents of 'drawable'

_A_u_t_h_o_r(_s):

     Derived by RGtkGen from GTK+ documentation

