gdk-pixbuf-Module-Interface      package:RGtk2      R Documentation

_M_o_d_u_l_e _I_n_t_e_r_f_a_c_e

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

     Extending

_M_e_t_h_o_d_s _a_n_d _F_u_n_c_t_i_o_n_s:

     'gdkPixbufSetOption(object, key, value)'
      'gdkPixbufGetFormats()'
      'gdkPixbufFormatGetName(object)'
      'gdkPixbufFormatGetDescription(object)'
      'gdkPixbufFormatGetMimeTypes(object)'
      'gdkPixbufFormatGetExtensions(object)'
      'gdkPixbufFormatIsWritable(object)'
      'gdkPixbufFormatIsScalable(object)'
      'gdkPixbufFormatIsDisabled(object)'
      'gdkPixbufFormatSetDisabled(object, disabled)'
      'gdkPixbufFormatGetLicense(object)'

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

     If 'gdk-pixbuf' has been compiled with GModule support, it can be
     extended by modules which can load (and perhaps also save) new
     image and animation formats. Each loadable module must export a
     'GdkPixbufModuleFillInfoFunc' function named 'fillInfo' and a
     'GdkPixbufModuleFillVtableFunc' function named 'fillVtable'.

     In order to make format-checking work before actually loading the
     modules (which may require dlopening image libraries), modules
     export their  signatures (and other information) via the
     'fillInfo' function. An external utility,
     'gdk-pixbuf-query-loaders',  uses this to create a text file
     containing a list of all available loaders and  their signatures.
     This file is then read at runtime by 'gdk-pixbuf' to obtain the
     list of available loaders and their signatures. 

     Modules may only implement a subset of the functionality available
     via 'GdkPixbufModule'. If a particular functionality is not
     implemented, the 'fillVtable' function will simply not set the
     corresponding function pointers of the 'GdkPixbufModule'
     structure. If a module supports incremental loading (i.e. provides
     'begin_load', 'stop_load' and 'load_increment'), it doesn't have
     to implement 'load', since 'gdk-pixbuf' can  supply a generic
     'load' implementation wrapping the incremental loading. 

     Installing a module is a two-step process:

        *  copy the module file(s) to the loader directory (normally
           'libdir', unless overridden by the environment variable
           'GDK_PIXBUF_MODULEDIR') 

        *  call 'gdk-pixbuf-query-loaders' to update the module file
           (normally 'sysconfdir', unless overridden by the environment
           variable 'GDK_PIXBUF_MODULE_FILE')

     The 'gdk-pixbuf' interfaces needed for implementing modules are
     contained in  'gdk-pixbuf-io.h' (and 'gdk-pixbuf-animation.h' if
     the module supports animations). They are not covered by the same
     stability guarantees as the regular  'gdk-pixbuf' API. To
     underline this fact, they are protected by  '#ifdef
     GDK_PIXBUF_ENABLE_BACKEND'.

_S_t_r_u_c_t_u_r_e_s:


     '_G_d_k_P_i_x_b_u_f_F_o_r_m_a_t' A 'GdkPixbufFormat' contains information about
          the image format accepted by a module. Only modules should
          access the fields directly, applications should use the
          'gdkPixbufFormat*' functions. Since 2.2

          '_n_a_m_e' [character] the name of the image format.

          '_s_i_g_n_a_t_u_r_e' [GdkPixbufModulePattern] the signature of the
               module.

          '_d_o_m_a_i_n' [character] the message domain for the
               'description'.

          '_d_e_s_c_r_i_p_t_i_o_n' [character] a description of the image format.

          '_m_i_m_e__t_y_p_e_s' [character] a list of MIME types for the image
               format.

          '_e_x_t_e_n_s_i_o_n_s' [character] a list of typical filename
               extensions for the image format.

          '_f_l_a_g_s' [numeric] a combination of 'GdkPixbufFormatFlags'.

          '_d_i_s_a_b_l_e_d' [logical] a boolean determining whether the loader
               is disabled.

          '_l_i_c_e_n_s_e' [character] a string containing license
               information, typically set to  shorthands like "GPL",
               "LGPL", etc.


_U_s_e_r _F_u_n_c_t_i_o_n_s:


     '_G_d_k_P_i_x_b_u_f_M_o_d_u_l_e_F_i_l_l_V_t_a_b_l_e_F_u_n_c(_m_o_d_u_l_e)' Defines the type of the
          function used to set the vtable of a  'GdkPixbufModule' when
          it is loaded.  Since 2.2

          '_m_o_d_u_l_e' [GdkPixbufModule] a 'GdkPixbufModule'.


     '_G_d_k_P_i_x_b_u_f_M_o_d_u_l_e_F_i_l_l_I_n_f_o_F_u_n_c(_i_n_f_o)' Defines the type of the
          function used to fill a  'GdkPixbufFormat' structure with
          information about a module. Since 2.2

          '_i_n_f_o' ['GdkPixbufFormat'] a 'GdkPixbufFormat'.


     '_G_d_k_P_i_x_b_u_f_M_o_d_u_l_e_S_i_z_e_F_u_n_c(_w_i_d_t_h, _h_e_i_g_h_t, _u_s_e_r._d_a_t_a)' Defines the
          type of the function that gets called once the size  of the
          loaded image is known.

          The function is expected to set 'width' and 'height' to the
          desired size to which the image should be scaled. If a module
          has no efficient  way to achieve the desired scaling during
          the loading of the image, it may either ignore the size
          request, or only approximate it - 'gdk-pixbuf' will then
          perform the required scaling on the completely loaded image. 

          If the function sets 'width' or 'height' to zero, the module
          should interpret this as a hint that it will be closed soon
          and shouldn't allocate further  resources. This convention is
          used to implement 'gdkPixbufGetFileInfo' efficiently. Since
          2.2

          '_w_i_d_t_h' [integer] pointer to a location containing the
               current image width

          '_h_e_i_g_h_t' [integer] pointer to a location containing the
               current image height

          '_u_s_e_r._d_a_t_a' [R object] the loader.


     '_G_d_k_P_i_x_b_u_f_M_o_d_u_l_e_P_r_e_p_a_r_e_d_F_u_n_c(_p_i_x_b_u_f, _a_n_i_m, _u_s_e_r._d_a_t_a)' Defines the
          type of the function that gets called once the initial  setup
          of 'pixbuf' is done. 'GdkPixbufLoader' uses a function of
          this type to emit the  "area_prepared" signal. Since 2.2

          '_p_i_x_b_u_f' ['GdkPixbuf'] the 'GdkPixbuf' that is currently
               being loaded.

          '_a_n_i_m' ['GdkPixbufAnimation'] if an animation is being
               loaded, the 'GdkPixbufAnimation', else 'NULL'.

          '_u_s_e_r._d_a_t_a' [R object] the loader.


     '_G_d_k_P_i_x_b_u_f_M_o_d_u_l_e_U_p_d_a_t_e_d_F_u_n_c(_p_i_x_b_u_f, _x, _y, _w_i_d_t_h, _h_e_i_g_h_t, _u_s_e_r._d_a_t_a)' 
          Defines the type of the function that gets called every time
          a region of 'pixbuf' is updated. 'GdkPixbufLoader' uses a
          function of this type to emit the  "area_updated" signal.
          Since 2.2

          '_p_i_x_b_u_f' ['GdkPixbuf'] the 'GdkPixbuf' that is currently
               being loaded.

          '_x' [integer] the X origin of the updated area.

          '_y' [integer] the Y origin of the updated area.

          '_w_i_d_t_h' [integer] the width of the updated area.

          '_h_e_i_g_h_t' [integer] the height of the updated area.

          '_u_s_e_r._d_a_t_a' [R object] the loader.


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

     Derived by RGtkGen from GTK+ documentation

_R_e_f_e_r_e_n_c_e_s:

     <URL:
     http://developer.gnome.org/doc/API/2.0/gdk-pixbuf/gdk-pixbuf-Module-Interface.html>

