<refentry id="gtkglext-gdkglpixmap">
<refmeta>
<refentrytitle>OpenGL Pixmap</refentrytitle>
<manvolnum>3</manvolnum>
<refmiscinfo>GTKGLEXT Library</refmiscinfo>
</refmeta>

<refnamediv>
<refname>OpenGL Pixmap</refname><refpurpose>OpenGL pixmap which is maintained off-screen</refpurpose>
</refnamediv>

<refsynopsisdiv><title>Synopsis</title>
<anchor id="GdkGLPixmap"/>
<synopsis>

#include &lt;gdk/gdkgl.h&gt;


            <link linkend="GdkGLPixmap-struct">GdkGLPixmap</link>;
<link linkend="GdkGLPixmap">GdkGLPixmap</link>* <link linkend="gdk-gl-pixmap-new">gdk_gl_pixmap_new</link>              (<link linkend="GdkGLConfig">GdkGLConfig</link> *glconfig,
                                             <link linkend="GdkPixmap">GdkPixmap</link> *pixmap,
                                             const <link linkend="int">int</link> *attrib_list);
<link linkend="void">void</link>        <link linkend="gdk-gl-pixmap-destroy">gdk_gl_pixmap_destroy</link>           (<link linkend="GdkGLPixmap">GdkGLPixmap</link> *glpixmap);
<link linkend="GdkPixmap">GdkPixmap</link>*  <link linkend="gdk-gl-pixmap-get-pixmap">gdk_gl_pixmap_get_pixmap</link>        (<link linkend="GdkGLPixmap">GdkGLPixmap</link> *glpixmap);
<link linkend="GdkGLPixmap">GdkGLPixmap</link>* <link linkend="gdk-pixmap-set-gl-capability">gdk_pixmap_set_gl_capability</link>   (<link linkend="GdkPixmap">GdkPixmap</link> *pixmap,
                                             <link linkend="GdkGLConfig">GdkGLConfig</link> *glconfig,
                                             const <link linkend="int">int</link> *attrib_list);
<link linkend="void">void</link>        <link linkend="gdk-pixmap-unset-gl-capability">gdk_pixmap_unset_gl_capability</link>  (<link linkend="GdkPixmap">GdkPixmap</link> *pixmap);
<link linkend="gboolean">gboolean</link>    <link linkend="gdk-pixmap-is-gl-capable">gdk_pixmap_is_gl_capable</link>        (<link linkend="GdkPixmap">GdkPixmap</link> *pixmap);
<link linkend="GdkGLPixmap">GdkGLPixmap</link>* <link linkend="gdk-pixmap-get-gl-pixmap">gdk_pixmap_get_gl_pixmap</link>       (<link linkend="GdkPixmap">GdkPixmap</link> *pixmap);
#define     <link linkend="gdk-pixmap-get-gl-drawable">gdk_pixmap_get_gl_drawable</link>      (pixmap)


</synopsis>
</refsynopsisdiv>

<refsect1>
<title>Object Hierarchy</title>
<synopsis>

  <link linkend="GObject">GObject</link>
   +----<link linkend="GdkDrawable">GdkDrawable</link>
         +----GdkGLPixmap
</synopsis>

</refsect1>








<refsect1>
<title>Description</title>
<para>

</para>
</refsect1>

<refsect1>
<title>Details</title>
<refsect2>
<title><anchor id="GdkGLPixmap-struct"/>GdkGLPixmap</title>
<indexterm><primary>GdkGLPixmap</primary></indexterm><programlisting>typedef struct _GdkGLPixmap GdkGLPixmap;</programlisting>
<para>

</para></refsect2>
<refsect2>
<title><anchor id="gdk-gl-pixmap-new"/>gdk_gl_pixmap_new ()</title>
<indexterm><primary>gdk_gl_pixmap_new</primary></indexterm><programlisting><link linkend="GdkGLPixmap">GdkGLPixmap</link>* gdk_gl_pixmap_new              (<link linkend="GdkGLConfig">GdkGLConfig</link> *glconfig,
                                             <link linkend="GdkPixmap">GdkPixmap</link> *pixmap,
                                             const <link linkend="int">int</link> *attrib_list);</programlisting>
<para>
Creates an off-screen rendering area.
attrib_list is currently unused. This must be set to NULL or empty
(first attribute of None). See GLX 1.3 spec.</para>
<para>

</para><variablelist role="params">
<varlistentry><term><parameter>glconfig</parameter>&nbsp;:</term>
<listitem><simpara> a <link linkend="GdkGLConfig"><type>GdkGLConfig</type></link>.
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>pixmap</parameter>&nbsp;:</term>
<listitem><simpara> the <link linkend="GdkPixmap"><type>GdkPixmap</type></link> to be used as the rendering area.
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>attrib_list</parameter>&nbsp;:</term>
<listitem><simpara> this must be set to NULL or empty (first attribute of None).
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&nbsp;:</term><listitem><simpara> the new <link linkend="GdkGLPixmap"><type>GdkGLPixmap</type></link>.
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2>
<title><anchor id="gdk-gl-pixmap-destroy"/>gdk_gl_pixmap_destroy ()</title>
<indexterm><primary>gdk_gl_pixmap_destroy</primary></indexterm><programlisting><link linkend="void">void</link>        gdk_gl_pixmap_destroy           (<link linkend="GdkGLPixmap">GdkGLPixmap</link> *glpixmap);</programlisting>
<para>
Destroys the OpenGL resources associated with <parameter>glpixmap</parameter> and
decrements <parameter>glpixmap</parameter>'s reference count.</para>
<para>

</para><variablelist role="params">
<varlistentry><term><parameter>glpixmap</parameter>&nbsp;:</term>
<listitem><simpara> a <link linkend="GdkGLPixmap"><type>GdkGLPixmap</type></link>.
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2>
<title><anchor id="gdk-gl-pixmap-get-pixmap"/>gdk_gl_pixmap_get_pixmap ()</title>
<indexterm><primary>gdk_gl_pixmap_get_pixmap</primary></indexterm><programlisting><link linkend="GdkPixmap">GdkPixmap</link>*  gdk_gl_pixmap_get_pixmap        (<link linkend="GdkGLPixmap">GdkGLPixmap</link> *glpixmap);</programlisting>
<para>
Returns the <link linkend="GdkPixmap"><type>GdkPixmap</type></link> associated with <parameter>glpixmap</parameter>.
</para>
<para>
Notice that <link linkend="GdkGLPixmap"><type>GdkGLPixmap</type></link> is not <link linkend="GdkPixmap"><type>GdkPixmap</type></link>, but another
<link linkend="GdkDrawable"><type>GdkDrawable</type></link> which have an associated <link linkend="GdkPixmap"><type>GdkPixmap</type></link>.</para>
<para>

</para><variablelist role="params">
<varlistentry><term><parameter>glpixmap</parameter>&nbsp;:</term>
<listitem><simpara> a <link linkend="GdkGLPixmap"><type>GdkGLPixmap</type></link>.
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&nbsp;:</term><listitem><simpara> the <link linkend="GdkPixmap"><type>GdkPixmap</type></link> associated with <parameter>glpixmap</parameter>.
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2>
<title><anchor id="gdk-pixmap-set-gl-capability"/>gdk_pixmap_set_gl_capability ()</title>
<indexterm><primary>gdk_pixmap_set_gl_capability</primary></indexterm><programlisting><link linkend="GdkGLPixmap">GdkGLPixmap</link>* gdk_pixmap_set_gl_capability   (<link linkend="GdkPixmap">GdkPixmap</link> *pixmap,
                                             <link linkend="GdkGLConfig">GdkGLConfig</link> *glconfig,
                                             const <link linkend="int">int</link> *attrib_list);</programlisting>
<para>
Set the OpenGL-capability to the <parameter>pixmap</parameter>.
This function creates a new <link linkend="GdkGLPixmap"><type>GdkGLPixmap</type></link> held by the <parameter>pixmap</parameter>.
attrib_list is currently unused. This must be set to NULL or empty
(first attribute of None).</para>
<para>

</para><variablelist role="params">
<varlistentry><term><parameter>pixmap</parameter>&nbsp;:</term>
<listitem><simpara> the <link linkend="GdkPixmap"><type>GdkPixmap</type></link> to be used as the rendering area.
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>glconfig</parameter>&nbsp;:</term>
<listitem><simpara> a <link linkend="GdkGLConfig"><type>GdkGLConfig</type></link>.
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>attrib_list</parameter>&nbsp;:</term>
<listitem><simpara> this must be set to NULL or empty (first attribute of None).
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&nbsp;:</term><listitem><simpara> the <link linkend="GdkGLPixmap"><type>GdkGLPixmap</type></link> used by the <parameter>pixmap</parameter> if it is successful,
              NULL otherwise.
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2>
<title><anchor id="gdk-pixmap-unset-gl-capability"/>gdk_pixmap_unset_gl_capability ()</title>
<indexterm><primary>gdk_pixmap_unset_gl_capability</primary></indexterm><programlisting><link linkend="void">void</link>        gdk_pixmap_unset_gl_capability  (<link linkend="GdkPixmap">GdkPixmap</link> *pixmap);</programlisting>
<para>
Unset the OpenGL-capability of the <parameter>pixmap</parameter>.
This function destroys the <link linkend="GdkGLPixmap"><type>GdkGLPixmap</type></link> held by the <parameter>pixmap</parameter>.</para>
<para>

</para><variablelist role="params">
<varlistentry><term><parameter>pixmap</parameter>&nbsp;:</term>
<listitem><simpara> a <link linkend="GdkPixmap"><type>GdkPixmap</type></link>.
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2>
<title><anchor id="gdk-pixmap-is-gl-capable"/>gdk_pixmap_is_gl_capable ()</title>
<indexterm><primary>gdk_pixmap_is_gl_capable</primary></indexterm><programlisting><link linkend="gboolean">gboolean</link>    gdk_pixmap_is_gl_capable        (<link linkend="GdkPixmap">GdkPixmap</link> *pixmap);</programlisting>
<para>
Returns whether the <parameter>pixmap</parameter> is OpenGL-capable.</para>
<para>

</para><variablelist role="params">
<varlistentry><term><parameter>pixmap</parameter>&nbsp;:</term>
<listitem><simpara> a <link linkend="GdkPixmap"><type>GdkPixmap</type></link>.
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&nbsp;:</term><listitem><simpara> TRUE if the <parameter>pixmap</parameter> is OpenGL-capable, FALSE otherwise.
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2>
<title><anchor id="gdk-pixmap-get-gl-pixmap"/>gdk_pixmap_get_gl_pixmap ()</title>
<indexterm><primary>gdk_pixmap_get_gl_pixmap</primary></indexterm><programlisting><link linkend="GdkGLPixmap">GdkGLPixmap</link>* gdk_pixmap_get_gl_pixmap       (<link linkend="GdkPixmap">GdkPixmap</link> *pixmap);</programlisting>
<para>
Returns the <link linkend="GdkGLPixmap"><type>GdkGLPixmap</type></link> held by the <parameter>pixmap</parameter>.</para>
<para>

</para><variablelist role="params">
<varlistentry><term><parameter>pixmap</parameter>&nbsp;:</term>
<listitem><simpara> a <link linkend="GdkPixmap"><type>GdkPixmap</type></link>.
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&nbsp;:</term><listitem><simpara> the <link linkend="GdkGLPixmap"><type>GdkGLPixmap</type></link>.
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2>
<title><anchor id="gdk-pixmap-get-gl-drawable"/>gdk_pixmap_get_gl_drawable()</title>
<indexterm><primary>gdk_pixmap_get_gl_drawable</primary></indexterm><programlisting>#define     gdk_pixmap_get_gl_drawable(pixmap)</programlisting>
<para>
Returns the <link linkend="GdkGLDrawable"><type>GdkGLDrawable</type></link> held by the <parameter>pixmap</parameter>. In fact, this is macro
that casts the result of <link linkend="gdk-pixmap-get-gl-pixmap"><type>gdk_pixmap_get_gl_pixmap</type></link> to <link linkend="GdkGLDrawable"><type>GdkGLDrawable</type></link>.
</para><variablelist role="params">
<varlistentry><term><parameter>pixmap</parameter>&nbsp;:</term>
<listitem><simpara>a <link linkend="GdkGLPixmap"><type>GdkGLPixmap</type></link>.
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&nbsp;:</term><listitem><simpara>the <link linkend="GdkGLDrawable"><type>GdkGLDrawable</type></link>.


</simpara></listitem></varlistentry>
</variablelist></refsect2>

</refsect1>




</refentry>
