2 <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
3 "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">
8 This manual page is licensed under the Creative Commons Attribution-ShareAlike 3.0 United States License (CC BY-SA 3.0
9 US). To view a copy of this license, visit http://creativecommons.org.license/by-sa/3.0/us.
13 id="waffle_get_proc_address"
14 xmlns:xi="http://www.w3.org/2001/XInclude">
16 <!-- See http://www.docbook.org/tdg/en/html/refentry.html. -->
19 <refentrytitle>waffle_get_proc_address</refentrytitle>
20 <manvolnum>3</manvolnum>
24 <refname>waffle_get_proc_address</refname>
25 <refpurpose>Query address of OpenGL functions</refpurpose>
29 <title>Waffle Manual</title>
30 <productname>waffle</productname>
31 <xi:include href="common/author-lina.versace.xml"/>
32 <xi:include href="common/copyright.xml"/>
33 <xi:include href="common/legalnotice.xml"/>
38 <funcsynopsis language="C">
41 #include <waffle.h>
45 <funcdef>void* <function>waffle_get_proc_address</function></funcdef>
46 <paramdef>const char *<parameter>name</parameter></paramdef>
53 <title>Description</title>
57 <term><function>waffle_get_proc_address()</function></term>
60 On GLX, this redirects to
61 <citerefentry><refentrytitle><function>glXGetProcAddress</function></refentrytitle><manvolnum>3</manvolnum></citerefentry>.
63 On EGL, this redirects to
64 <citerefentry><refentrytitle><function>eglGetProcAddress</function></refentrytitle><manvolnum>3</manvolnum></citerefentry>.
66 On CGL, this function returns <constant>NULL</constant>
68 because there exists no <function>CGLGetProcAdress()</function>.
70 On WGL, this redirects to
71 <citerefentry><refentrytitle><function>wglGetProcAddress</function></refentrytitle><manvolnum>3</manvolnum></citerefentry>.
75 Some aspects of this function's behavior are platform-specific and non-intuitive.
82 If the queried function is not available,
84 <function>waffle_get_proc_address()</function> may return a non-null pointer.
90 If the queried function is statically exposed by the OpenGL library of a given API,
92 then <function>waffle_get_proc_address()</function> may return a <constant>NULL</constant>.
98 Under Windows (WGL) a current context must be available before executing the function.
100 Otherwise <function>waffle_get_proc_address()</function> may return a <constant>NULL</constant>.
107 For details on this function's behavior,
109 see the specification for the relevant platform:
111 the <ulink url="http://www.opengl.org/registry/doc/glx1.4.pdf">GLX 1.4 Specification</ulink>
113 the <ulink url="http://www.khronos.org/registry/egl/specs/eglspec.1.4.20110406.pdf">EGL 1.4 Specification</ulink>
115 or the <ulink url="http://msdn.microsoft.com/en-gb/library/windows/desktop/dd374386(v=vs.85).aspx">MSDN article</ulink>.
123 <title>Errors</title>
125 <xi:include href="common/error-codes.xml"/>
128 No errors are specific to any functions listed in this manual page.
132 <xi:include href="common/issues.xml"/>
135 <title>See Also</title>
137 <citerefentry><refentrytitle>waffle</refentrytitle><manvolnum>7</manvolnum></citerefentry>,
138 <citerefentry><refentrytitle>waffle_dl_sym</refentrytitle><manvolnum>3</manvolnum></citerefentry>
145 vim:tw=120 et ts=2 sw=2: