1 <?xml version=
"1.0" encoding=
"UTF-8"?>
2 <!DOCTYPE book PUBLIC
"-//OASIS//DTD DocBook MathML Module V1.1b1//EN"
3 "http://www.oasis-open.org/docbook/xml/mathml/1.1CR1/dbmathml.dtd">
4 <refentry id=
"glXQueryDrawable">
9 <holder>Silicon Graphics, Inc.
</holder>
12 <refentrytitle>glXQueryDrawable
</refentrytitle>
13 <manvolnum>3G
</manvolnum>
16 <refname>glXQueryDrawable
</refname>
17 <refpurpose>returns an attribute assoicated with a GLX drawable
</refpurpose>
19 <refsynopsisdiv><title>C Specification
</title>
22 <funcdef>int
<function>glXQueryDrawable
</function></funcdef>
23 <paramdef>Display *
<parameter>dpy
</parameter></paramdef>
24 <paramdef>GLXDrawable
<parameter>draw
</parameter></paramdef>
25 <paramdef>int
<parameter>attribute
</parameter></paramdef>
26 <paramdef>unsigned int *
<parameter>value
</parameter></paramdef>
30 <!-- eqn: ignoring delim $$ -->
31 <refsect1 id=
"parameters"><title>Parameters
</title>
34 <term><parameter>dpy
</parameter></term>
37 Specifies the connection to the X server.
42 <term><parameter>draw
</parameter></term>
45 Specifies the GLX drawable to be queried.
50 <term><parameter>attribute
</parameter></term>
53 Specifies the attribute to be returned. Must be one of
54 <constant>GLX_WIDTH
</constant>,
55 <constant>GLX_HEIGHT
</constant>,
56 <constant>GLX_PRESERVED_CONTENTS
</constant>,
57 <constant>GLX_LARGEST_PBUFFER
</constant>, or
58 <constant>GLX_FBCONFIG_ID
</constant>.
63 <term><parameter>value
</parameter></term>
66 Contains the return value for
67 <parameter>attribute
</parameter>.
73 <refsect1 id=
"description"><title>Description
</title>
75 <function>glXQueryDrawable
</function> sets
76 <parameter>value
</parameter> to the value of
77 <parameter>attribute
</parameter> with respect to the GLXDrawable
78 <parameter>draw
</parameter>.
81 <parameter>attribute
</parameter> may be one of the following:
85 <term><constant>GLX_WIDTH
</constant></term>
88 Returns the width of
<parameter>ctx
</parameter>.
93 <term><constant>GLX_HEIGHT
</constant></term>
96 Returns the height of
<parameter>ctx
</parameter>.
101 <term><constant>GLX_PRESERVED_CONTENTS
</constant></term>
104 Returns
<constant>True
</constant> if the contents
105 of a GLXPbuffer are preserved when a resource
106 conflict occurs;
<constant>False
</constant> otherwise.
111 <term><constant>GLX_LARGEST_PBUFFER
</constant></term>
114 Returns the value set when
115 <function>glXCreatePbuffer
</function> was called to
116 create the GLXPbuffer. If
117 <constant>False
</constant> is returned, then the
118 call to
<function>glXCreatePbuffer
</function> will
119 fail to create a GLXPbuffer if the requested size
120 is larger than the implementation maximum or
121 available resources. If
<constant>True
</constant>
122 is returned, a GLXPbuffer of the maximum availble
123 size (if less than the requested width and height)
129 <term><constant>GLX_FBCONFIG_ID
</constant></term>
132 Returns the XID for
<parameter>draw
</parameter>.
138 If
<parameter>draw
</parameter> is a GLXWindow or GLXPixmap and
139 <parameter>attribute
</parameter> is set to
140 <constant>GLX_PRESERVED_CONTENTS
</constant> or
141 <constant>GLX_LARGETST_PBUFFER
</constant>, the contents of
142 <parameter>value
</parameter> are undefined. If
143 <parameter>attribute
</parameter> is not one of the attributes
144 listed above, the contents of
<parameter>value
</parameter> are
148 <refsect1 id=
"errors"><title>Errors
</title>
150 A
<constant>GLXBadDrawable
</constant> is generated if
151 <parameter>draw
</parameter> is not a valid GLXDrawable.
154 <refsect1 id=
"seealso"><title>See Also
</title>
156 <citerefentry><refentrytitle>glXCreateWindow
</refentrytitle></citerefentry>,
157 <citerefentry><refentrytitle>glXCreatePixmap
</refentrytitle></citerefentry>,
158 <citerefentry><refentrytitle>glXCreatePbuffer
</refentrytitle></citerefentry>,
159 <citerefentry><refentrytitle>glXGetFBConfigAttrib
</refentrytitle></citerefentry>,
160 <citerefentry><refentrytitle>glXChooseFBConfig
</refentrytitle></citerefentry>
163 <refsect1 id=
"Copyright"><title>Copyright
</title>
165 Copyright
<trademark class=
"copyright"></trademark> 1991-
2006
166 Silicon Graphics, Inc. This document is licensed under the SGI
167 Free Software B License. For details, see
168 <ulink url=
"http://oss.sgi.com/projects/FreeB/">http://oss.sgi.com/projects/FreeB/
</ulink>.