~ubuntu-branches/ubuntu/gutsy/gtkglext/gutsy

« back to all changes in this revision

Viewing changes to gdk/x11/gdkglglxext.c

  • Committer: Bazaar Package Importer
  • Author(s): Marcelo E. Magallon
  • Date: 2004-04-03 17:43:17 UTC
  • Revision ID: james.westby@ubuntu.com-20040403174317-d5gb2d2gftaligp8
Tags: upstream-1.0.6
ImportĀ upstreamĀ versionĀ 1.0.6

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* GdkGLExt - OpenGL Extension to GDK
 
2
 * Copyright (C) 2002-2004  Naofumi Yasufuku
 
3
 *
 
4
 * This library is free software; you can redistribute it and/or
 
5
 * modify it under the terms of the GNU Lesser General Public
 
6
 * License as published by the Free Software Foundation; either
 
7
 * version 2.1 of the License, or (at your option) any later version.
 
8
 *
 
9
 * This library is distributed in the hope that it will be useful,
 
10
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 
11
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 
12
 * Lesser General Public License for more details.
 
13
 *
 
14
 * You should have received a copy of the GNU Lesser General Public
 
15
 * License along with this library; if not, write to the Free Software
 
16
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307  USA.
 
17
 */
 
18
 
 
19
/*
 
20
 * This is a generated file.  Please modify "gen-gdkglglxext-c.pl".
 
21
 */
 
22
 
 
23
#include "gdkglx.h"
 
24
#include "gdkglprivate-x11.h"
 
25
#include "gdkglglxext.h"
 
26
 
 
27
/*
 
28
 * GLX_VERSION_1_3
 
29
 */
 
30
 
 
31
static GdkGL_GLX_VERSION_1_3 _procs_GLX_VERSION_1_3 = {
 
32
  (GdkGLProc_glXGetFBConfigs) -1,
 
33
  (GdkGLProc_glXChooseFBConfig) -1,
 
34
  (GdkGLProc_glXGetFBConfigAttrib) -1,
 
35
  (GdkGLProc_glXGetVisualFromFBConfig) -1,
 
36
  (GdkGLProc_glXCreateWindow) -1,
 
37
  (GdkGLProc_glXDestroyWindow) -1,
 
38
  (GdkGLProc_glXCreatePixmap) -1,
 
39
  (GdkGLProc_glXDestroyPixmap) -1,
 
40
  (GdkGLProc_glXCreatePbuffer) -1,
 
41
  (GdkGLProc_glXDestroyPbuffer) -1,
 
42
  (GdkGLProc_glXQueryDrawable) -1,
 
43
  (GdkGLProc_glXCreateNewContext) -1,
 
44
  (GdkGLProc_glXMakeContextCurrent) -1,
 
45
  (GdkGLProc_glXGetCurrentReadDrawable) -1,
 
46
  (GdkGLProc_glXGetCurrentDisplay) -1,
 
47
  (GdkGLProc_glXQueryContext) -1,
 
48
  (GdkGLProc_glXSelectEvent) -1,
 
49
  (GdkGLProc_glXGetSelectedEvent) -1
 
50
};
 
51
 
 
52
/* glXGetFBConfigs */
 
53
GdkGLProc
 
54
gdk_gl_get_glXGetFBConfigs (void)
 
55
{
 
56
  if (_procs_GLX_VERSION_1_3.glXGetFBConfigs == (GdkGLProc_glXGetFBConfigs) -1)
 
57
    _procs_GLX_VERSION_1_3.glXGetFBConfigs =
 
58
      (GdkGLProc_glXGetFBConfigs) gdk_gl_get_proc_address ("glXGetFBConfigs");
 
59
 
 
60
  GDK_GL_NOTE (MISC,
 
61
    g_message (" - gdk_gl_get_glXGetFBConfigs () - %s",
 
62
               (_procs_GLX_VERSION_1_3.glXGetFBConfigs) ? "supported" : "not supported"));
 
63
 
 
64
  return (GdkGLProc) (_procs_GLX_VERSION_1_3.glXGetFBConfigs);
 
65
}
 
66
 
 
67
/* glXChooseFBConfig */
 
68
GdkGLProc
 
69
gdk_gl_get_glXChooseFBConfig (void)
 
70
{
 
71
  if (_procs_GLX_VERSION_1_3.glXChooseFBConfig == (GdkGLProc_glXChooseFBConfig) -1)
 
72
    _procs_GLX_VERSION_1_3.glXChooseFBConfig =
 
73
      (GdkGLProc_glXChooseFBConfig) gdk_gl_get_proc_address ("glXChooseFBConfig");
 
74
 
 
75
  GDK_GL_NOTE (MISC,
 
76
    g_message (" - gdk_gl_get_glXChooseFBConfig () - %s",
 
77
               (_procs_GLX_VERSION_1_3.glXChooseFBConfig) ? "supported" : "not supported"));
 
78
 
 
79
  return (GdkGLProc) (_procs_GLX_VERSION_1_3.glXChooseFBConfig);
 
80
}
 
81
 
 
82
/* glXGetFBConfigAttrib */
 
83
GdkGLProc
 
84
gdk_gl_get_glXGetFBConfigAttrib (void)
 
85
{
 
86
  if (_procs_GLX_VERSION_1_3.glXGetFBConfigAttrib == (GdkGLProc_glXGetFBConfigAttrib) -1)
 
87
    _procs_GLX_VERSION_1_3.glXGetFBConfigAttrib =
 
88
      (GdkGLProc_glXGetFBConfigAttrib) gdk_gl_get_proc_address ("glXGetFBConfigAttrib");
 
89
 
 
90
  GDK_GL_NOTE (MISC,
 
91
    g_message (" - gdk_gl_get_glXGetFBConfigAttrib () - %s",
 
92
               (_procs_GLX_VERSION_1_3.glXGetFBConfigAttrib) ? "supported" : "not supported"));
 
93
 
 
94
  return (GdkGLProc) (_procs_GLX_VERSION_1_3.glXGetFBConfigAttrib);
 
95
}
 
96
 
 
97
/* glXGetVisualFromFBConfig */
 
98
GdkGLProc
 
99
gdk_gl_get_glXGetVisualFromFBConfig (void)
 
100
{
 
101
  if (_procs_GLX_VERSION_1_3.glXGetVisualFromFBConfig == (GdkGLProc_glXGetVisualFromFBConfig) -1)
 
102
    _procs_GLX_VERSION_1_3.glXGetVisualFromFBConfig =
 
103
      (GdkGLProc_glXGetVisualFromFBConfig) gdk_gl_get_proc_address ("glXGetVisualFromFBConfig");
 
104
 
 
105
  GDK_GL_NOTE (MISC,
 
106
    g_message (" - gdk_gl_get_glXGetVisualFromFBConfig () - %s",
 
107
               (_procs_GLX_VERSION_1_3.glXGetVisualFromFBConfig) ? "supported" : "not supported"));
 
108
 
 
109
  return (GdkGLProc) (_procs_GLX_VERSION_1_3.glXGetVisualFromFBConfig);
 
110
}
 
111
 
 
112
/* glXCreateWindow */
 
113
GdkGLProc
 
114
gdk_gl_get_glXCreateWindow (void)
 
115
{
 
116
  if (_procs_GLX_VERSION_1_3.glXCreateWindow == (GdkGLProc_glXCreateWindow) -1)
 
117
    _procs_GLX_VERSION_1_3.glXCreateWindow =
 
118
      (GdkGLProc_glXCreateWindow) gdk_gl_get_proc_address ("glXCreateWindow");
 
119
 
 
120
  GDK_GL_NOTE (MISC,
 
121
    g_message (" - gdk_gl_get_glXCreateWindow () - %s",
 
122
               (_procs_GLX_VERSION_1_3.glXCreateWindow) ? "supported" : "not supported"));
 
123
 
 
124
  return (GdkGLProc) (_procs_GLX_VERSION_1_3.glXCreateWindow);
 
125
}
 
126
 
 
127
/* glXDestroyWindow */
 
128
GdkGLProc
 
129
gdk_gl_get_glXDestroyWindow (void)
 
130
{
 
131
  if (_procs_GLX_VERSION_1_3.glXDestroyWindow == (GdkGLProc_glXDestroyWindow) -1)
 
132
    _procs_GLX_VERSION_1_3.glXDestroyWindow =
 
133
      (GdkGLProc_glXDestroyWindow) gdk_gl_get_proc_address ("glXDestroyWindow");
 
134
 
 
135
  GDK_GL_NOTE (MISC,
 
136
    g_message (" - gdk_gl_get_glXDestroyWindow () - %s",
 
137
               (_procs_GLX_VERSION_1_3.glXDestroyWindow) ? "supported" : "not supported"));
 
138
 
 
139
  return (GdkGLProc) (_procs_GLX_VERSION_1_3.glXDestroyWindow);
 
140
}
 
141
 
 
142
/* glXCreatePixmap */
 
143
GdkGLProc
 
144
gdk_gl_get_glXCreatePixmap (void)
 
145
{
 
146
  if (_procs_GLX_VERSION_1_3.glXCreatePixmap == (GdkGLProc_glXCreatePixmap) -1)
 
147
    _procs_GLX_VERSION_1_3.glXCreatePixmap =
 
148
      (GdkGLProc_glXCreatePixmap) gdk_gl_get_proc_address ("glXCreatePixmap");
 
149
 
 
150
  GDK_GL_NOTE (MISC,
 
151
    g_message (" - gdk_gl_get_glXCreatePixmap () - %s",
 
152
               (_procs_GLX_VERSION_1_3.glXCreatePixmap) ? "supported" : "not supported"));
 
153
 
 
154
  return (GdkGLProc) (_procs_GLX_VERSION_1_3.glXCreatePixmap);
 
155
}
 
156
 
 
157
/* glXDestroyPixmap */
 
158
GdkGLProc
 
159
gdk_gl_get_glXDestroyPixmap (void)
 
160
{
 
161
  if (_procs_GLX_VERSION_1_3.glXDestroyPixmap == (GdkGLProc_glXDestroyPixmap) -1)
 
162
    _procs_GLX_VERSION_1_3.glXDestroyPixmap =
 
163
      (GdkGLProc_glXDestroyPixmap) gdk_gl_get_proc_address ("glXDestroyPixmap");
 
164
 
 
165
  GDK_GL_NOTE (MISC,
 
166
    g_message (" - gdk_gl_get_glXDestroyPixmap () - %s",
 
167
               (_procs_GLX_VERSION_1_3.glXDestroyPixmap) ? "supported" : "not supported"));
 
168
 
 
169
  return (GdkGLProc) (_procs_GLX_VERSION_1_3.glXDestroyPixmap);
 
170
}
 
171
 
 
172
/* glXCreatePbuffer */
 
173
GdkGLProc
 
174
gdk_gl_get_glXCreatePbuffer (void)
 
175
{
 
176
  if (_procs_GLX_VERSION_1_3.glXCreatePbuffer == (GdkGLProc_glXCreatePbuffer) -1)
 
177
    _procs_GLX_VERSION_1_3.glXCreatePbuffer =
 
178
      (GdkGLProc_glXCreatePbuffer) gdk_gl_get_proc_address ("glXCreatePbuffer");
 
179
 
 
180
  GDK_GL_NOTE (MISC,
 
181
    g_message (" - gdk_gl_get_glXCreatePbuffer () - %s",
 
182
               (_procs_GLX_VERSION_1_3.glXCreatePbuffer) ? "supported" : "not supported"));
 
183
 
 
184
  return (GdkGLProc) (_procs_GLX_VERSION_1_3.glXCreatePbuffer);
 
185
}
 
186
 
 
187
/* glXDestroyPbuffer */
 
188
GdkGLProc
 
189
gdk_gl_get_glXDestroyPbuffer (void)
 
190
{
 
191
  if (_procs_GLX_VERSION_1_3.glXDestroyPbuffer == (GdkGLProc_glXDestroyPbuffer) -1)
 
192
    _procs_GLX_VERSION_1_3.glXDestroyPbuffer =
 
193
      (GdkGLProc_glXDestroyPbuffer) gdk_gl_get_proc_address ("glXDestroyPbuffer");
 
194
 
 
195
  GDK_GL_NOTE (MISC,
 
196
    g_message (" - gdk_gl_get_glXDestroyPbuffer () - %s",
 
197
               (_procs_GLX_VERSION_1_3.glXDestroyPbuffer) ? "supported" : "not supported"));
 
198
 
 
199
  return (GdkGLProc) (_procs_GLX_VERSION_1_3.glXDestroyPbuffer);
 
200
}
 
201
 
 
202
/* glXQueryDrawable */
 
203
GdkGLProc
 
204
gdk_gl_get_glXQueryDrawable (void)
 
205
{
 
206
  if (_procs_GLX_VERSION_1_3.glXQueryDrawable == (GdkGLProc_glXQueryDrawable) -1)
 
207
    _procs_GLX_VERSION_1_3.glXQueryDrawable =
 
208
      (GdkGLProc_glXQueryDrawable) gdk_gl_get_proc_address ("glXQueryDrawable");
 
209
 
 
210
  GDK_GL_NOTE (MISC,
 
211
    g_message (" - gdk_gl_get_glXQueryDrawable () - %s",
 
212
               (_procs_GLX_VERSION_1_3.glXQueryDrawable) ? "supported" : "not supported"));
 
213
 
 
214
  return (GdkGLProc) (_procs_GLX_VERSION_1_3.glXQueryDrawable);
 
215
}
 
216
 
 
217
/* glXCreateNewContext */
 
218
GdkGLProc
 
219
gdk_gl_get_glXCreateNewContext (void)
 
220
{
 
221
  if (_procs_GLX_VERSION_1_3.glXCreateNewContext == (GdkGLProc_glXCreateNewContext) -1)
 
222
    _procs_GLX_VERSION_1_3.glXCreateNewContext =
 
223
      (GdkGLProc_glXCreateNewContext) gdk_gl_get_proc_address ("glXCreateNewContext");
 
224
 
 
225
  GDK_GL_NOTE (MISC,
 
226
    g_message (" - gdk_gl_get_glXCreateNewContext () - %s",
 
227
               (_procs_GLX_VERSION_1_3.glXCreateNewContext) ? "supported" : "not supported"));
 
228
 
 
229
  return (GdkGLProc) (_procs_GLX_VERSION_1_3.glXCreateNewContext);
 
230
}
 
231
 
 
232
/* glXMakeContextCurrent */
 
233
GdkGLProc
 
234
gdk_gl_get_glXMakeContextCurrent (void)
 
235
{
 
236
  if (_procs_GLX_VERSION_1_3.glXMakeContextCurrent == (GdkGLProc_glXMakeContextCurrent) -1)
 
237
    _procs_GLX_VERSION_1_3.glXMakeContextCurrent =
 
238
      (GdkGLProc_glXMakeContextCurrent) gdk_gl_get_proc_address ("glXMakeContextCurrent");
 
239
 
 
240
  GDK_GL_NOTE (MISC,
 
241
    g_message (" - gdk_gl_get_glXMakeContextCurrent () - %s",
 
242
               (_procs_GLX_VERSION_1_3.glXMakeContextCurrent) ? "supported" : "not supported"));
 
243
 
 
244
  return (GdkGLProc) (_procs_GLX_VERSION_1_3.glXMakeContextCurrent);
 
245
}
 
246
 
 
247
/* glXGetCurrentReadDrawable */
 
248
GdkGLProc
 
249
gdk_gl_get_glXGetCurrentReadDrawable (void)
 
250
{
 
251
  if (_procs_GLX_VERSION_1_3.glXGetCurrentReadDrawable == (GdkGLProc_glXGetCurrentReadDrawable) -1)
 
252
    _procs_GLX_VERSION_1_3.glXGetCurrentReadDrawable =
 
253
      (GdkGLProc_glXGetCurrentReadDrawable) gdk_gl_get_proc_address ("glXGetCurrentReadDrawable");
 
254
 
 
255
  GDK_GL_NOTE (MISC,
 
256
    g_message (" - gdk_gl_get_glXGetCurrentReadDrawable () - %s",
 
257
               (_procs_GLX_VERSION_1_3.glXGetCurrentReadDrawable) ? "supported" : "not supported"));
 
258
 
 
259
  return (GdkGLProc) (_procs_GLX_VERSION_1_3.glXGetCurrentReadDrawable);
 
260
}
 
261
 
 
262
/* glXGetCurrentDisplay */
 
263
GdkGLProc
 
264
gdk_gl_get_glXGetCurrentDisplay (void)
 
265
{
 
266
  if (_procs_GLX_VERSION_1_3.glXGetCurrentDisplay == (GdkGLProc_glXGetCurrentDisplay) -1)
 
267
    _procs_GLX_VERSION_1_3.glXGetCurrentDisplay =
 
268
      (GdkGLProc_glXGetCurrentDisplay) gdk_gl_get_proc_address ("glXGetCurrentDisplay");
 
269
 
 
270
  GDK_GL_NOTE (MISC,
 
271
    g_message (" - gdk_gl_get_glXGetCurrentDisplay () - %s",
 
272
               (_procs_GLX_VERSION_1_3.glXGetCurrentDisplay) ? "supported" : "not supported"));
 
273
 
 
274
  return (GdkGLProc) (_procs_GLX_VERSION_1_3.glXGetCurrentDisplay);
 
275
}
 
276
 
 
277
/* glXQueryContext */
 
278
GdkGLProc
 
279
gdk_gl_get_glXQueryContext (void)
 
280
{
 
281
  if (_procs_GLX_VERSION_1_3.glXQueryContext == (GdkGLProc_glXQueryContext) -1)
 
282
    _procs_GLX_VERSION_1_3.glXQueryContext =
 
283
      (GdkGLProc_glXQueryContext) gdk_gl_get_proc_address ("glXQueryContext");
 
284
 
 
285
  GDK_GL_NOTE (MISC,
 
286
    g_message (" - gdk_gl_get_glXQueryContext () - %s",
 
287
               (_procs_GLX_VERSION_1_3.glXQueryContext) ? "supported" : "not supported"));
 
288
 
 
289
  return (GdkGLProc) (_procs_GLX_VERSION_1_3.glXQueryContext);
 
290
}
 
291
 
 
292
/* glXSelectEvent */
 
293
GdkGLProc
 
294
gdk_gl_get_glXSelectEvent (void)
 
295
{
 
296
  if (_procs_GLX_VERSION_1_3.glXSelectEvent == (GdkGLProc_glXSelectEvent) -1)
 
297
    _procs_GLX_VERSION_1_3.glXSelectEvent =
 
298
      (GdkGLProc_glXSelectEvent) gdk_gl_get_proc_address ("glXSelectEvent");
 
299
 
 
300
  GDK_GL_NOTE (MISC,
 
301
    g_message (" - gdk_gl_get_glXSelectEvent () - %s",
 
302
               (_procs_GLX_VERSION_1_3.glXSelectEvent) ? "supported" : "not supported"));
 
303
 
 
304
  return (GdkGLProc) (_procs_GLX_VERSION_1_3.glXSelectEvent);
 
305
}
 
306
 
 
307
/* glXGetSelectedEvent */
 
308
GdkGLProc
 
309
gdk_gl_get_glXGetSelectedEvent (void)
 
310
{
 
311
  if (_procs_GLX_VERSION_1_3.glXGetSelectedEvent == (GdkGLProc_glXGetSelectedEvent) -1)
 
312
    _procs_GLX_VERSION_1_3.glXGetSelectedEvent =
 
313
      (GdkGLProc_glXGetSelectedEvent) gdk_gl_get_proc_address ("glXGetSelectedEvent");
 
314
 
 
315
  GDK_GL_NOTE (MISC,
 
316
    g_message (" - gdk_gl_get_glXGetSelectedEvent () - %s",
 
317
               (_procs_GLX_VERSION_1_3.glXGetSelectedEvent) ? "supported" : "not supported"));
 
318
 
 
319
  return (GdkGLProc) (_procs_GLX_VERSION_1_3.glXGetSelectedEvent);
 
320
}
 
321
 
 
322
/* Get GLX_VERSION_1_3 functions */
 
323
GdkGL_GLX_VERSION_1_3 *
 
324
gdk_gl_get_GLX_VERSION_1_3 (void)
 
325
{
 
326
  static gint supported = -1;
 
327
 
 
328
  if (supported == -1)
 
329
    {
 
330
      supported =  (gdk_gl_get_glXGetFBConfigs () != NULL);
 
331
      supported &= (gdk_gl_get_glXChooseFBConfig () != NULL);
 
332
      supported &= (gdk_gl_get_glXGetFBConfigAttrib () != NULL);
 
333
      supported &= (gdk_gl_get_glXGetVisualFromFBConfig () != NULL);
 
334
      supported &= (gdk_gl_get_glXCreateWindow () != NULL);
 
335
      supported &= (gdk_gl_get_glXDestroyWindow () != NULL);
 
336
      supported &= (gdk_gl_get_glXCreatePixmap () != NULL);
 
337
      supported &= (gdk_gl_get_glXDestroyPixmap () != NULL);
 
338
      supported &= (gdk_gl_get_glXCreatePbuffer () != NULL);
 
339
      supported &= (gdk_gl_get_glXDestroyPbuffer () != NULL);
 
340
      supported &= (gdk_gl_get_glXQueryDrawable () != NULL);
 
341
      supported &= (gdk_gl_get_glXCreateNewContext () != NULL);
 
342
      supported &= (gdk_gl_get_glXMakeContextCurrent () != NULL);
 
343
      supported &= (gdk_gl_get_glXGetCurrentReadDrawable () != NULL);
 
344
      supported &= (gdk_gl_get_glXGetCurrentDisplay () != NULL);
 
345
      supported &= (gdk_gl_get_glXQueryContext () != NULL);
 
346
      supported &= (gdk_gl_get_glXSelectEvent () != NULL);
 
347
      supported &= (gdk_gl_get_glXGetSelectedEvent () != NULL);
 
348
    }
 
349
 
 
350
  GDK_GL_NOTE (MISC,
 
351
    g_message (" - gdk_gl_get_GLX_VERSION_1_3 () - %s",
 
352
               (supported) ? "supported" : "not supported"));
 
353
 
 
354
  if (!supported)
 
355
    return NULL;
 
356
 
 
357
  return &_procs_GLX_VERSION_1_3;
 
358
}
 
359
 
 
360
/*
 
361
 * GLX_VERSION_1_4
 
362
 */
 
363
 
 
364
static GdkGL_GLX_VERSION_1_4 _procs_GLX_VERSION_1_4 = {
 
365
  (GdkGLProc_glXGetProcAddress) -1
 
366
};
 
367
 
 
368
/* glXGetProcAddress */
 
369
GdkGLProc
 
370
gdk_gl_get_glXGetProcAddress (void)
 
371
{
 
372
  if (_procs_GLX_VERSION_1_4.glXGetProcAddress == (GdkGLProc_glXGetProcAddress) -1)
 
373
    _procs_GLX_VERSION_1_4.glXGetProcAddress =
 
374
      (GdkGLProc_glXGetProcAddress) gdk_gl_get_proc_address ("glXGetProcAddress");
 
375
 
 
376
  GDK_GL_NOTE (MISC,
 
377
    g_message (" - gdk_gl_get_glXGetProcAddress () - %s",
 
378
               (_procs_GLX_VERSION_1_4.glXGetProcAddress) ? "supported" : "not supported"));
 
379
 
 
380
  return (GdkGLProc) (_procs_GLX_VERSION_1_4.glXGetProcAddress);
 
381
}
 
382
 
 
383
/* Get GLX_VERSION_1_4 functions */
 
384
GdkGL_GLX_VERSION_1_4 *
 
385
gdk_gl_get_GLX_VERSION_1_4 (void)
 
386
{
 
387
  static gint supported = -1;
 
388
 
 
389
  if (supported == -1)
 
390
    {
 
391
      supported =  (gdk_gl_get_glXGetProcAddress () != NULL);
 
392
    }
 
393
 
 
394
  GDK_GL_NOTE (MISC,
 
395
    g_message (" - gdk_gl_get_GLX_VERSION_1_4 () - %s",
 
396
               (supported) ? "supported" : "not supported"));
 
397
 
 
398
  if (!supported)
 
399
    return NULL;
 
400
 
 
401
  return &_procs_GLX_VERSION_1_4;
 
402
}
 
403
 
 
404
/*
 
405
 * GLX_ARB_get_proc_address
 
406
 */
 
407
 
 
408
static GdkGL_GLX_ARB_get_proc_address _procs_GLX_ARB_get_proc_address = {
 
409
  (GdkGLProc_glXGetProcAddressARB) -1
 
410
};
 
411
 
 
412
/* glXGetProcAddressARB */
 
413
GdkGLProc
 
414
gdk_gl_get_glXGetProcAddressARB (void)
 
415
{
 
416
  if (_procs_GLX_ARB_get_proc_address.glXGetProcAddressARB == (GdkGLProc_glXGetProcAddressARB) -1)
 
417
    _procs_GLX_ARB_get_proc_address.glXGetProcAddressARB =
 
418
      (GdkGLProc_glXGetProcAddressARB) gdk_gl_get_proc_address ("glXGetProcAddressARB");
 
419
 
 
420
  GDK_GL_NOTE (MISC,
 
421
    g_message (" - gdk_gl_get_glXGetProcAddressARB () - %s",
 
422
               (_procs_GLX_ARB_get_proc_address.glXGetProcAddressARB) ? "supported" : "not supported"));
 
423
 
 
424
  return (GdkGLProc) (_procs_GLX_ARB_get_proc_address.glXGetProcAddressARB);
 
425
}
 
426
 
 
427
/* Get GLX_ARB_get_proc_address functions */
 
428
GdkGL_GLX_ARB_get_proc_address *
 
429
gdk_gl_get_GLX_ARB_get_proc_address (GdkGLConfig *glconfig)
 
430
{
 
431
  static gint supported = -1;
 
432
 
 
433
  if (supported == -1)
 
434
    {
 
435
      supported = gdk_x11_gl_query_glx_extension (glconfig, "GLX_ARB_get_proc_address");
 
436
 
 
437
      if (supported)
 
438
        {
 
439
          supported &= (gdk_gl_get_glXGetProcAddressARB () != NULL);
 
440
        }
 
441
    }
 
442
 
 
443
  GDK_GL_NOTE (MISC,
 
444
    g_message (" - gdk_gl_get_GLX_ARB_get_proc_address () - %s",
 
445
               (supported) ? "supported" : "not supported"));
 
446
 
 
447
  if (!supported)
 
448
    return NULL;
 
449
 
 
450
  return &_procs_GLX_ARB_get_proc_address;
 
451
}
 
452
 
 
453
/*
 
454
 * GLX_SGI_swap_control
 
455
 */
 
456
 
 
457
static GdkGL_GLX_SGI_swap_control _procs_GLX_SGI_swap_control = {
 
458
  (GdkGLProc_glXSwapIntervalSGI) -1
 
459
};
 
460
 
 
461
/* glXSwapIntervalSGI */
 
462
GdkGLProc
 
463
gdk_gl_get_glXSwapIntervalSGI (void)
 
464
{
 
465
  if (_procs_GLX_SGI_swap_control.glXSwapIntervalSGI == (GdkGLProc_glXSwapIntervalSGI) -1)
 
466
    _procs_GLX_SGI_swap_control.glXSwapIntervalSGI =
 
467
      (GdkGLProc_glXSwapIntervalSGI) gdk_gl_get_proc_address ("glXSwapIntervalSGI");
 
468
 
 
469
  GDK_GL_NOTE (MISC,
 
470
    g_message (" - gdk_gl_get_glXSwapIntervalSGI () - %s",
 
471
               (_procs_GLX_SGI_swap_control.glXSwapIntervalSGI) ? "supported" : "not supported"));
 
472
 
 
473
  return (GdkGLProc) (_procs_GLX_SGI_swap_control.glXSwapIntervalSGI);
 
474
}
 
475
 
 
476
/* Get GLX_SGI_swap_control functions */
 
477
GdkGL_GLX_SGI_swap_control *
 
478
gdk_gl_get_GLX_SGI_swap_control (GdkGLConfig *glconfig)
 
479
{
 
480
  static gint supported = -1;
 
481
 
 
482
  if (supported == -1)
 
483
    {
 
484
      supported = gdk_x11_gl_query_glx_extension (glconfig, "GLX_SGI_swap_control");
 
485
 
 
486
      if (supported)
 
487
        {
 
488
          supported &= (gdk_gl_get_glXSwapIntervalSGI () != NULL);
 
489
        }
 
490
    }
 
491
 
 
492
  GDK_GL_NOTE (MISC,
 
493
    g_message (" - gdk_gl_get_GLX_SGI_swap_control () - %s",
 
494
               (supported) ? "supported" : "not supported"));
 
495
 
 
496
  if (!supported)
 
497
    return NULL;
 
498
 
 
499
  return &_procs_GLX_SGI_swap_control;
 
500
}
 
501
 
 
502
/*
 
503
 * GLX_SGI_video_sync
 
504
 */
 
505
 
 
506
static GdkGL_GLX_SGI_video_sync _procs_GLX_SGI_video_sync = {
 
507
  (GdkGLProc_glXGetVideoSyncSGI) -1,
 
508
  (GdkGLProc_glXWaitVideoSyncSGI) -1
 
509
};
 
510
 
 
511
/* glXGetVideoSyncSGI */
 
512
GdkGLProc
 
513
gdk_gl_get_glXGetVideoSyncSGI (void)
 
514
{
 
515
  if (_procs_GLX_SGI_video_sync.glXGetVideoSyncSGI == (GdkGLProc_glXGetVideoSyncSGI) -1)
 
516
    _procs_GLX_SGI_video_sync.glXGetVideoSyncSGI =
 
517
      (GdkGLProc_glXGetVideoSyncSGI) gdk_gl_get_proc_address ("glXGetVideoSyncSGI");
 
518
 
 
519
  GDK_GL_NOTE (MISC,
 
520
    g_message (" - gdk_gl_get_glXGetVideoSyncSGI () - %s",
 
521
               (_procs_GLX_SGI_video_sync.glXGetVideoSyncSGI) ? "supported" : "not supported"));
 
522
 
 
523
  return (GdkGLProc) (_procs_GLX_SGI_video_sync.glXGetVideoSyncSGI);
 
524
}
 
525
 
 
526
/* glXWaitVideoSyncSGI */
 
527
GdkGLProc
 
528
gdk_gl_get_glXWaitVideoSyncSGI (void)
 
529
{
 
530
  if (_procs_GLX_SGI_video_sync.glXWaitVideoSyncSGI == (GdkGLProc_glXWaitVideoSyncSGI) -1)
 
531
    _procs_GLX_SGI_video_sync.glXWaitVideoSyncSGI =
 
532
      (GdkGLProc_glXWaitVideoSyncSGI) gdk_gl_get_proc_address ("glXWaitVideoSyncSGI");
 
533
 
 
534
  GDK_GL_NOTE (MISC,
 
535
    g_message (" - gdk_gl_get_glXWaitVideoSyncSGI () - %s",
 
536
               (_procs_GLX_SGI_video_sync.glXWaitVideoSyncSGI) ? "supported" : "not supported"));
 
537
 
 
538
  return (GdkGLProc) (_procs_GLX_SGI_video_sync.glXWaitVideoSyncSGI);
 
539
}
 
540
 
 
541
/* Get GLX_SGI_video_sync functions */
 
542
GdkGL_GLX_SGI_video_sync *
 
543
gdk_gl_get_GLX_SGI_video_sync (GdkGLConfig *glconfig)
 
544
{
 
545
  static gint supported = -1;
 
546
 
 
547
  if (supported == -1)
 
548
    {
 
549
      supported = gdk_x11_gl_query_glx_extension (glconfig, "GLX_SGI_video_sync");
 
550
 
 
551
      if (supported)
 
552
        {
 
553
          supported &= (gdk_gl_get_glXGetVideoSyncSGI () != NULL);
 
554
          supported &= (gdk_gl_get_glXWaitVideoSyncSGI () != NULL);
 
555
        }
 
556
    }
 
557
 
 
558
  GDK_GL_NOTE (MISC,
 
559
    g_message (" - gdk_gl_get_GLX_SGI_video_sync () - %s",
 
560
               (supported) ? "supported" : "not supported"));
 
561
 
 
562
  if (!supported)
 
563
    return NULL;
 
564
 
 
565
  return &_procs_GLX_SGI_video_sync;
 
566
}
 
567
 
 
568
/*
 
569
 * GLX_SGI_make_current_read
 
570
 */
 
571
 
 
572
static GdkGL_GLX_SGI_make_current_read _procs_GLX_SGI_make_current_read = {
 
573
  (GdkGLProc_glXMakeCurrentReadSGI) -1,
 
574
  (GdkGLProc_glXGetCurrentReadDrawableSGI) -1
 
575
};
 
576
 
 
577
/* glXMakeCurrentReadSGI */
 
578
GdkGLProc
 
579
gdk_gl_get_glXMakeCurrentReadSGI (void)
 
580
{
 
581
  if (_procs_GLX_SGI_make_current_read.glXMakeCurrentReadSGI == (GdkGLProc_glXMakeCurrentReadSGI) -1)
 
582
    _procs_GLX_SGI_make_current_read.glXMakeCurrentReadSGI =
 
583
      (GdkGLProc_glXMakeCurrentReadSGI) gdk_gl_get_proc_address ("glXMakeCurrentReadSGI");
 
584
 
 
585
  GDK_GL_NOTE (MISC,
 
586
    g_message (" - gdk_gl_get_glXMakeCurrentReadSGI () - %s",
 
587
               (_procs_GLX_SGI_make_current_read.glXMakeCurrentReadSGI) ? "supported" : "not supported"));
 
588
 
 
589
  return (GdkGLProc) (_procs_GLX_SGI_make_current_read.glXMakeCurrentReadSGI);
 
590
}
 
591
 
 
592
/* glXGetCurrentReadDrawableSGI */
 
593
GdkGLProc
 
594
gdk_gl_get_glXGetCurrentReadDrawableSGI (void)
 
595
{
 
596
  if (_procs_GLX_SGI_make_current_read.glXGetCurrentReadDrawableSGI == (GdkGLProc_glXGetCurrentReadDrawableSGI) -1)
 
597
    _procs_GLX_SGI_make_current_read.glXGetCurrentReadDrawableSGI =
 
598
      (GdkGLProc_glXGetCurrentReadDrawableSGI) gdk_gl_get_proc_address ("glXGetCurrentReadDrawableSGI");
 
599
 
 
600
  GDK_GL_NOTE (MISC,
 
601
    g_message (" - gdk_gl_get_glXGetCurrentReadDrawableSGI () - %s",
 
602
               (_procs_GLX_SGI_make_current_read.glXGetCurrentReadDrawableSGI) ? "supported" : "not supported"));
 
603
 
 
604
  return (GdkGLProc) (_procs_GLX_SGI_make_current_read.glXGetCurrentReadDrawableSGI);
 
605
}
 
606
 
 
607
/* Get GLX_SGI_make_current_read functions */
 
608
GdkGL_GLX_SGI_make_current_read *
 
609
gdk_gl_get_GLX_SGI_make_current_read (GdkGLConfig *glconfig)
 
610
{
 
611
  static gint supported = -1;
 
612
 
 
613
  if (supported == -1)
 
614
    {
 
615
      supported = gdk_x11_gl_query_glx_extension (glconfig, "GLX_SGI_make_current_read");
 
616
 
 
617
      if (supported)
 
618
        {
 
619
          supported &= (gdk_gl_get_glXMakeCurrentReadSGI () != NULL);
 
620
          supported &= (gdk_gl_get_glXGetCurrentReadDrawableSGI () != NULL);
 
621
        }
 
622
    }
 
623
 
 
624
  GDK_GL_NOTE (MISC,
 
625
    g_message (" - gdk_gl_get_GLX_SGI_make_current_read () - %s",
 
626
               (supported) ? "supported" : "not supported"));
 
627
 
 
628
  if (!supported)
 
629
    return NULL;
 
630
 
 
631
  return &_procs_GLX_SGI_make_current_read;
 
632
}
 
633
 
 
634
/*
 
635
 * GLX_SGIX_video_source
 
636
 */
 
637
 
 
638
#ifdef _VL_H
 
639
 
 
640
static GdkGL_GLX_SGIX_video_source _procs_GLX_SGIX_video_source = {
 
641
  (GdkGLProc_glXCreateGLXVideoSourceSGIX) -1,
 
642
  (GdkGLProc_glXDestroyGLXVideoSourceSGIX) -1
 
643
};
 
644
 
 
645
/* glXCreateGLXVideoSourceSGIX */
 
646
GdkGLProc
 
647
gdk_gl_get_glXCreateGLXVideoSourceSGIX (void)
 
648
{
 
649
  if (_procs_GLX_SGIX_video_source.glXCreateGLXVideoSourceSGIX == (GdkGLProc_glXCreateGLXVideoSourceSGIX) -1)
 
650
    _procs_GLX_SGIX_video_source.glXCreateGLXVideoSourceSGIX =
 
651
      (GdkGLProc_glXCreateGLXVideoSourceSGIX) gdk_gl_get_proc_address ("glXCreateGLXVideoSourceSGIX");
 
652
 
 
653
  GDK_GL_NOTE (MISC,
 
654
    g_message (" - gdk_gl_get_glXCreateGLXVideoSourceSGIX () - %s",
 
655
               (_procs_GLX_SGIX_video_source.glXCreateGLXVideoSourceSGIX) ? "supported" : "not supported"));
 
656
 
 
657
  return (GdkGLProc) (_procs_GLX_SGIX_video_source.glXCreateGLXVideoSourceSGIX);
 
658
}
 
659
 
 
660
/* glXDestroyGLXVideoSourceSGIX */
 
661
GdkGLProc
 
662
gdk_gl_get_glXDestroyGLXVideoSourceSGIX (void)
 
663
{
 
664
  if (_procs_GLX_SGIX_video_source.glXDestroyGLXVideoSourceSGIX == (GdkGLProc_glXDestroyGLXVideoSourceSGIX) -1)
 
665
    _procs_GLX_SGIX_video_source.glXDestroyGLXVideoSourceSGIX =
 
666
      (GdkGLProc_glXDestroyGLXVideoSourceSGIX) gdk_gl_get_proc_address ("glXDestroyGLXVideoSourceSGIX");
 
667
 
 
668
  GDK_GL_NOTE (MISC,
 
669
    g_message (" - gdk_gl_get_glXDestroyGLXVideoSourceSGIX () - %s",
 
670
               (_procs_GLX_SGIX_video_source.glXDestroyGLXVideoSourceSGIX) ? "supported" : "not supported"));
 
671
 
 
672
  return (GdkGLProc) (_procs_GLX_SGIX_video_source.glXDestroyGLXVideoSourceSGIX);
 
673
}
 
674
 
 
675
/* Get GLX_SGIX_video_source functions */
 
676
GdkGL_GLX_SGIX_video_source *
 
677
gdk_gl_get_GLX_SGIX_video_source (GdkGLConfig *glconfig)
 
678
{
 
679
  static gint supported = -1;
 
680
 
 
681
  if (supported == -1)
 
682
    {
 
683
      supported = gdk_x11_gl_query_glx_extension (glconfig, "GLX_SGIX_video_source");
 
684
 
 
685
      if (supported)
 
686
        {
 
687
          supported &= (gdk_gl_get_glXCreateGLXVideoSourceSGIX () != NULL);
 
688
          supported &= (gdk_gl_get_glXDestroyGLXVideoSourceSGIX () != NULL);
 
689
        }
 
690
    }
 
691
 
 
692
  GDK_GL_NOTE (MISC,
 
693
    g_message (" - gdk_gl_get_GLX_SGIX_video_source () - %s",
 
694
               (supported) ? "supported" : "not supported"));
 
695
 
 
696
  if (!supported)
 
697
    return NULL;
 
698
 
 
699
  return &_procs_GLX_SGIX_video_source;
 
700
}
 
701
 
 
702
#endif /* _VL_H */
 
703
 
 
704
/*
 
705
 * GLX_EXT_import_context
 
706
 */
 
707
 
 
708
static GdkGL_GLX_EXT_import_context _procs_GLX_EXT_import_context = {
 
709
  (GdkGLProc_glXGetCurrentDisplayEXT) -1,
 
710
  (GdkGLProc_glXQueryContextInfoEXT) -1,
 
711
  (GdkGLProc_glXGetContextIDEXT) -1,
 
712
  (GdkGLProc_glXImportContextEXT) -1,
 
713
  (GdkGLProc_glXFreeContextEXT) -1
 
714
};
 
715
 
 
716
/* glXGetCurrentDisplayEXT */
 
717
GdkGLProc
 
718
gdk_gl_get_glXGetCurrentDisplayEXT (void)
 
719
{
 
720
  if (_procs_GLX_EXT_import_context.glXGetCurrentDisplayEXT == (GdkGLProc_glXGetCurrentDisplayEXT) -1)
 
721
    _procs_GLX_EXT_import_context.glXGetCurrentDisplayEXT =
 
722
      (GdkGLProc_glXGetCurrentDisplayEXT) gdk_gl_get_proc_address ("glXGetCurrentDisplayEXT");
 
723
 
 
724
  GDK_GL_NOTE (MISC,
 
725
    g_message (" - gdk_gl_get_glXGetCurrentDisplayEXT () - %s",
 
726
               (_procs_GLX_EXT_import_context.glXGetCurrentDisplayEXT) ? "supported" : "not supported"));
 
727
 
 
728
  return (GdkGLProc) (_procs_GLX_EXT_import_context.glXGetCurrentDisplayEXT);
 
729
}
 
730
 
 
731
/* glXQueryContextInfoEXT */
 
732
GdkGLProc
 
733
gdk_gl_get_glXQueryContextInfoEXT (void)
 
734
{
 
735
  if (_procs_GLX_EXT_import_context.glXQueryContextInfoEXT == (GdkGLProc_glXQueryContextInfoEXT) -1)
 
736
    _procs_GLX_EXT_import_context.glXQueryContextInfoEXT =
 
737
      (GdkGLProc_glXQueryContextInfoEXT) gdk_gl_get_proc_address ("glXQueryContextInfoEXT");
 
738
 
 
739
  GDK_GL_NOTE (MISC,
 
740
    g_message (" - gdk_gl_get_glXQueryContextInfoEXT () - %s",
 
741
               (_procs_GLX_EXT_import_context.glXQueryContextInfoEXT) ? "supported" : "not supported"));
 
742
 
 
743
  return (GdkGLProc) (_procs_GLX_EXT_import_context.glXQueryContextInfoEXT);
 
744
}
 
745
 
 
746
/* glXGetContextIDEXT */
 
747
GdkGLProc
 
748
gdk_gl_get_glXGetContextIDEXT (void)
 
749
{
 
750
  if (_procs_GLX_EXT_import_context.glXGetContextIDEXT == (GdkGLProc_glXGetContextIDEXT) -1)
 
751
    _procs_GLX_EXT_import_context.glXGetContextIDEXT =
 
752
      (GdkGLProc_glXGetContextIDEXT) gdk_gl_get_proc_address ("glXGetContextIDEXT");
 
753
 
 
754
  GDK_GL_NOTE (MISC,
 
755
    g_message (" - gdk_gl_get_glXGetContextIDEXT () - %s",
 
756
               (_procs_GLX_EXT_import_context.glXGetContextIDEXT) ? "supported" : "not supported"));
 
757
 
 
758
  return (GdkGLProc) (_procs_GLX_EXT_import_context.glXGetContextIDEXT);
 
759
}
 
760
 
 
761
/* glXImportContextEXT */
 
762
GdkGLProc
 
763
gdk_gl_get_glXImportContextEXT (void)
 
764
{
 
765
  if (_procs_GLX_EXT_import_context.glXImportContextEXT == (GdkGLProc_glXImportContextEXT) -1)
 
766
    _procs_GLX_EXT_import_context.glXImportContextEXT =
 
767
      (GdkGLProc_glXImportContextEXT) gdk_gl_get_proc_address ("glXImportContextEXT");
 
768
 
 
769
  GDK_GL_NOTE (MISC,
 
770
    g_message (" - gdk_gl_get_glXImportContextEXT () - %s",
 
771
               (_procs_GLX_EXT_import_context.glXImportContextEXT) ? "supported" : "not supported"));
 
772
 
 
773
  return (GdkGLProc) (_procs_GLX_EXT_import_context.glXImportContextEXT);
 
774
}
 
775
 
 
776
/* glXFreeContextEXT */
 
777
GdkGLProc
 
778
gdk_gl_get_glXFreeContextEXT (void)
 
779
{
 
780
  if (_procs_GLX_EXT_import_context.glXFreeContextEXT == (GdkGLProc_glXFreeContextEXT) -1)
 
781
    _procs_GLX_EXT_import_context.glXFreeContextEXT =
 
782
      (GdkGLProc_glXFreeContextEXT) gdk_gl_get_proc_address ("glXFreeContextEXT");
 
783
 
 
784
  GDK_GL_NOTE (MISC,
 
785
    g_message (" - gdk_gl_get_glXFreeContextEXT () - %s",
 
786
               (_procs_GLX_EXT_import_context.glXFreeContextEXT) ? "supported" : "not supported"));
 
787
 
 
788
  return (GdkGLProc) (_procs_GLX_EXT_import_context.glXFreeContextEXT);
 
789
}
 
790
 
 
791
/* Get GLX_EXT_import_context functions */
 
792
GdkGL_GLX_EXT_import_context *
 
793
gdk_gl_get_GLX_EXT_import_context (GdkGLConfig *glconfig)
 
794
{
 
795
  static gint supported = -1;
 
796
 
 
797
  if (supported == -1)
 
798
    {
 
799
      supported = gdk_x11_gl_query_glx_extension (glconfig, "GLX_EXT_import_context");
 
800
 
 
801
      if (supported)
 
802
        {
 
803
          supported &= (gdk_gl_get_glXGetCurrentDisplayEXT () != NULL);
 
804
          supported &= (gdk_gl_get_glXQueryContextInfoEXT () != NULL);
 
805
          supported &= (gdk_gl_get_glXGetContextIDEXT () != NULL);
 
806
          supported &= (gdk_gl_get_glXImportContextEXT () != NULL);
 
807
          supported &= (gdk_gl_get_glXFreeContextEXT () != NULL);
 
808
        }
 
809
    }
 
810
 
 
811
  GDK_GL_NOTE (MISC,
 
812
    g_message (" - gdk_gl_get_GLX_EXT_import_context () - %s",
 
813
               (supported) ? "supported" : "not supported"));
 
814
 
 
815
  if (!supported)
 
816
    return NULL;
 
817
 
 
818
  return &_procs_GLX_EXT_import_context;
 
819
}
 
820
 
 
821
/*
 
822
 * GLX_SGIX_fbconfig
 
823
 */
 
824
 
 
825
static GdkGL_GLX_SGIX_fbconfig _procs_GLX_SGIX_fbconfig = {
 
826
  (GdkGLProc_glXGetFBConfigAttribSGIX) -1,
 
827
  (GdkGLProc_glXChooseFBConfigSGIX) -1,
 
828
  (GdkGLProc_glXCreateGLXPixmapWithConfigSGIX) -1,
 
829
  (GdkGLProc_glXCreateContextWithConfigSGIX) -1,
 
830
  (GdkGLProc_glXGetVisualFromFBConfigSGIX) -1,
 
831
  (GdkGLProc_glXGetFBConfigFromVisualSGIX) -1
 
832
};
 
833
 
 
834
/* glXGetFBConfigAttribSGIX */
 
835
GdkGLProc
 
836
gdk_gl_get_glXGetFBConfigAttribSGIX (void)
 
837
{
 
838
  if (_procs_GLX_SGIX_fbconfig.glXGetFBConfigAttribSGIX == (GdkGLProc_glXGetFBConfigAttribSGIX) -1)
 
839
    _procs_GLX_SGIX_fbconfig.glXGetFBConfigAttribSGIX =
 
840
      (GdkGLProc_glXGetFBConfigAttribSGIX) gdk_gl_get_proc_address ("glXGetFBConfigAttribSGIX");
 
841
 
 
842
  GDK_GL_NOTE (MISC,
 
843
    g_message (" - gdk_gl_get_glXGetFBConfigAttribSGIX () - %s",
 
844
               (_procs_GLX_SGIX_fbconfig.glXGetFBConfigAttribSGIX) ? "supported" : "not supported"));
 
845
 
 
846
  return (GdkGLProc) (_procs_GLX_SGIX_fbconfig.glXGetFBConfigAttribSGIX);
 
847
}
 
848
 
 
849
/* glXChooseFBConfigSGIX */
 
850
GdkGLProc
 
851
gdk_gl_get_glXChooseFBConfigSGIX (void)
 
852
{
 
853
  if (_procs_GLX_SGIX_fbconfig.glXChooseFBConfigSGIX == (GdkGLProc_glXChooseFBConfigSGIX) -1)
 
854
    _procs_GLX_SGIX_fbconfig.glXChooseFBConfigSGIX =
 
855
      (GdkGLProc_glXChooseFBConfigSGIX) gdk_gl_get_proc_address ("glXChooseFBConfigSGIX");
 
856
 
 
857
  GDK_GL_NOTE (MISC,
 
858
    g_message (" - gdk_gl_get_glXChooseFBConfigSGIX () - %s",
 
859
               (_procs_GLX_SGIX_fbconfig.glXChooseFBConfigSGIX) ? "supported" : "not supported"));
 
860
 
 
861
  return (GdkGLProc) (_procs_GLX_SGIX_fbconfig.glXChooseFBConfigSGIX);
 
862
}
 
863
 
 
864
/* glXCreateGLXPixmapWithConfigSGIX */
 
865
GdkGLProc
 
866
gdk_gl_get_glXCreateGLXPixmapWithConfigSGIX (void)
 
867
{
 
868
  if (_procs_GLX_SGIX_fbconfig.glXCreateGLXPixmapWithConfigSGIX == (GdkGLProc_glXCreateGLXPixmapWithConfigSGIX) -1)
 
869
    _procs_GLX_SGIX_fbconfig.glXCreateGLXPixmapWithConfigSGIX =
 
870
      (GdkGLProc_glXCreateGLXPixmapWithConfigSGIX) gdk_gl_get_proc_address ("glXCreateGLXPixmapWithConfigSGIX");
 
871
 
 
872
  GDK_GL_NOTE (MISC,
 
873
    g_message (" - gdk_gl_get_glXCreateGLXPixmapWithConfigSGIX () - %s",
 
874
               (_procs_GLX_SGIX_fbconfig.glXCreateGLXPixmapWithConfigSGIX) ? "supported" : "not supported"));
 
875
 
 
876
  return (GdkGLProc) (_procs_GLX_SGIX_fbconfig.glXCreateGLXPixmapWithConfigSGIX);
 
877
}
 
878
 
 
879
/* glXCreateContextWithConfigSGIX */
 
880
GdkGLProc
 
881
gdk_gl_get_glXCreateContextWithConfigSGIX (void)
 
882
{
 
883
  if (_procs_GLX_SGIX_fbconfig.glXCreateContextWithConfigSGIX == (GdkGLProc_glXCreateContextWithConfigSGIX) -1)
 
884
    _procs_GLX_SGIX_fbconfig.glXCreateContextWithConfigSGIX =
 
885
      (GdkGLProc_glXCreateContextWithConfigSGIX) gdk_gl_get_proc_address ("glXCreateContextWithConfigSGIX");
 
886
 
 
887
  GDK_GL_NOTE (MISC,
 
888
    g_message (" - gdk_gl_get_glXCreateContextWithConfigSGIX () - %s",
 
889
               (_procs_GLX_SGIX_fbconfig.glXCreateContextWithConfigSGIX) ? "supported" : "not supported"));
 
890
 
 
891
  return (GdkGLProc) (_procs_GLX_SGIX_fbconfig.glXCreateContextWithConfigSGIX);
 
892
}
 
893
 
 
894
/* glXGetVisualFromFBConfigSGIX */
 
895
GdkGLProc
 
896
gdk_gl_get_glXGetVisualFromFBConfigSGIX (void)
 
897
{
 
898
  if (_procs_GLX_SGIX_fbconfig.glXGetVisualFromFBConfigSGIX == (GdkGLProc_glXGetVisualFromFBConfigSGIX) -1)
 
899
    _procs_GLX_SGIX_fbconfig.glXGetVisualFromFBConfigSGIX =
 
900
      (GdkGLProc_glXGetVisualFromFBConfigSGIX) gdk_gl_get_proc_address ("glXGetVisualFromFBConfigSGIX");
 
901
 
 
902
  GDK_GL_NOTE (MISC,
 
903
    g_message (" - gdk_gl_get_glXGetVisualFromFBConfigSGIX () - %s",
 
904
               (_procs_GLX_SGIX_fbconfig.glXGetVisualFromFBConfigSGIX) ? "supported" : "not supported"));
 
905
 
 
906
  return (GdkGLProc) (_procs_GLX_SGIX_fbconfig.glXGetVisualFromFBConfigSGIX);
 
907
}
 
908
 
 
909
/* glXGetFBConfigFromVisualSGIX */
 
910
GdkGLProc
 
911
gdk_gl_get_glXGetFBConfigFromVisualSGIX (void)
 
912
{
 
913
  if (_procs_GLX_SGIX_fbconfig.glXGetFBConfigFromVisualSGIX == (GdkGLProc_glXGetFBConfigFromVisualSGIX) -1)
 
914
    _procs_GLX_SGIX_fbconfig.glXGetFBConfigFromVisualSGIX =
 
915
      (GdkGLProc_glXGetFBConfigFromVisualSGIX) gdk_gl_get_proc_address ("glXGetFBConfigFromVisualSGIX");
 
916
 
 
917
  GDK_GL_NOTE (MISC,
 
918
    g_message (" - gdk_gl_get_glXGetFBConfigFromVisualSGIX () - %s",
 
919
               (_procs_GLX_SGIX_fbconfig.glXGetFBConfigFromVisualSGIX) ? "supported" : "not supported"));
 
920
 
 
921
  return (GdkGLProc) (_procs_GLX_SGIX_fbconfig.glXGetFBConfigFromVisualSGIX);
 
922
}
 
923
 
 
924
/* Get GLX_SGIX_fbconfig functions */
 
925
GdkGL_GLX_SGIX_fbconfig *
 
926
gdk_gl_get_GLX_SGIX_fbconfig (GdkGLConfig *glconfig)
 
927
{
 
928
  static gint supported = -1;
 
929
 
 
930
  if (supported == -1)
 
931
    {
 
932
      supported = gdk_x11_gl_query_glx_extension (glconfig, "GLX_SGIX_fbconfig");
 
933
 
 
934
      if (supported)
 
935
        {
 
936
          supported &= (gdk_gl_get_glXGetFBConfigAttribSGIX () != NULL);
 
937
          supported &= (gdk_gl_get_glXChooseFBConfigSGIX () != NULL);
 
938
          supported &= (gdk_gl_get_glXCreateGLXPixmapWithConfigSGIX () != NULL);
 
939
          supported &= (gdk_gl_get_glXCreateContextWithConfigSGIX () != NULL);
 
940
          supported &= (gdk_gl_get_glXGetVisualFromFBConfigSGIX () != NULL);
 
941
          supported &= (gdk_gl_get_glXGetFBConfigFromVisualSGIX () != NULL);
 
942
        }
 
943
    }
 
944
 
 
945
  GDK_GL_NOTE (MISC,
 
946
    g_message (" - gdk_gl_get_GLX_SGIX_fbconfig () - %s",
 
947
               (supported) ? "supported" : "not supported"));
 
948
 
 
949
  if (!supported)
 
950
    return NULL;
 
951
 
 
952
  return &_procs_GLX_SGIX_fbconfig;
 
953
}
 
954
 
 
955
/*
 
956
 * GLX_SGIX_pbuffer
 
957
 */
 
958
 
 
959
static GdkGL_GLX_SGIX_pbuffer _procs_GLX_SGIX_pbuffer = {
 
960
  (GdkGLProc_glXCreateGLXPbufferSGIX) -1,
 
961
  (GdkGLProc_glXDestroyGLXPbufferSGIX) -1,
 
962
  (GdkGLProc_glXQueryGLXPbufferSGIX) -1,
 
963
  (GdkGLProc_glXSelectEventSGIX) -1,
 
964
  (GdkGLProc_glXGetSelectedEventSGIX) -1
 
965
};
 
966
 
 
967
/* glXCreateGLXPbufferSGIX */
 
968
GdkGLProc
 
969
gdk_gl_get_glXCreateGLXPbufferSGIX (void)
 
970
{
 
971
  if (_procs_GLX_SGIX_pbuffer.glXCreateGLXPbufferSGIX == (GdkGLProc_glXCreateGLXPbufferSGIX) -1)
 
972
    _procs_GLX_SGIX_pbuffer.glXCreateGLXPbufferSGIX =
 
973
      (GdkGLProc_glXCreateGLXPbufferSGIX) gdk_gl_get_proc_address ("glXCreateGLXPbufferSGIX");
 
974
 
 
975
  GDK_GL_NOTE (MISC,
 
976
    g_message (" - gdk_gl_get_glXCreateGLXPbufferSGIX () - %s",
 
977
               (_procs_GLX_SGIX_pbuffer.glXCreateGLXPbufferSGIX) ? "supported" : "not supported"));
 
978
 
 
979
  return (GdkGLProc) (_procs_GLX_SGIX_pbuffer.glXCreateGLXPbufferSGIX);
 
980
}
 
981
 
 
982
/* glXDestroyGLXPbufferSGIX */
 
983
GdkGLProc
 
984
gdk_gl_get_glXDestroyGLXPbufferSGIX (void)
 
985
{
 
986
  if (_procs_GLX_SGIX_pbuffer.glXDestroyGLXPbufferSGIX == (GdkGLProc_glXDestroyGLXPbufferSGIX) -1)
 
987
    _procs_GLX_SGIX_pbuffer.glXDestroyGLXPbufferSGIX =
 
988
      (GdkGLProc_glXDestroyGLXPbufferSGIX) gdk_gl_get_proc_address ("glXDestroyGLXPbufferSGIX");
 
989
 
 
990
  GDK_GL_NOTE (MISC,
 
991
    g_message (" - gdk_gl_get_glXDestroyGLXPbufferSGIX () - %s",
 
992
               (_procs_GLX_SGIX_pbuffer.glXDestroyGLXPbufferSGIX) ? "supported" : "not supported"));
 
993
 
 
994
  return (GdkGLProc) (_procs_GLX_SGIX_pbuffer.glXDestroyGLXPbufferSGIX);
 
995
}
 
996
 
 
997
/* glXQueryGLXPbufferSGIX */
 
998
GdkGLProc
 
999
gdk_gl_get_glXQueryGLXPbufferSGIX (void)
 
1000
{
 
1001
  if (_procs_GLX_SGIX_pbuffer.glXQueryGLXPbufferSGIX == (GdkGLProc_glXQueryGLXPbufferSGIX) -1)
 
1002
    _procs_GLX_SGIX_pbuffer.glXQueryGLXPbufferSGIX =
 
1003
      (GdkGLProc_glXQueryGLXPbufferSGIX) gdk_gl_get_proc_address ("glXQueryGLXPbufferSGIX");
 
1004
 
 
1005
  GDK_GL_NOTE (MISC,
 
1006
    g_message (" - gdk_gl_get_glXQueryGLXPbufferSGIX () - %s",
 
1007
               (_procs_GLX_SGIX_pbuffer.glXQueryGLXPbufferSGIX) ? "supported" : "not supported"));
 
1008
 
 
1009
  return (GdkGLProc) (_procs_GLX_SGIX_pbuffer.glXQueryGLXPbufferSGIX);
 
1010
}
 
1011
 
 
1012
/* glXSelectEventSGIX */
 
1013
GdkGLProc
 
1014
gdk_gl_get_glXSelectEventSGIX (void)
 
1015
{
 
1016
  if (_procs_GLX_SGIX_pbuffer.glXSelectEventSGIX == (GdkGLProc_glXSelectEventSGIX) -1)
 
1017
    _procs_GLX_SGIX_pbuffer.glXSelectEventSGIX =
 
1018
      (GdkGLProc_glXSelectEventSGIX) gdk_gl_get_proc_address ("glXSelectEventSGIX");
 
1019
 
 
1020
  GDK_GL_NOTE (MISC,
 
1021
    g_message (" - gdk_gl_get_glXSelectEventSGIX () - %s",
 
1022
               (_procs_GLX_SGIX_pbuffer.glXSelectEventSGIX) ? "supported" : "not supported"));
 
1023
 
 
1024
  return (GdkGLProc) (_procs_GLX_SGIX_pbuffer.glXSelectEventSGIX);
 
1025
}
 
1026
 
 
1027
/* glXGetSelectedEventSGIX */
 
1028
GdkGLProc
 
1029
gdk_gl_get_glXGetSelectedEventSGIX (void)
 
1030
{
 
1031
  if (_procs_GLX_SGIX_pbuffer.glXGetSelectedEventSGIX == (GdkGLProc_glXGetSelectedEventSGIX) -1)
 
1032
    _procs_GLX_SGIX_pbuffer.glXGetSelectedEventSGIX =
 
1033
      (GdkGLProc_glXGetSelectedEventSGIX) gdk_gl_get_proc_address ("glXGetSelectedEventSGIX");
 
1034
 
 
1035
  GDK_GL_NOTE (MISC,
 
1036
    g_message (" - gdk_gl_get_glXGetSelectedEventSGIX () - %s",
 
1037
               (_procs_GLX_SGIX_pbuffer.glXGetSelectedEventSGIX) ? "supported" : "not supported"));
 
1038
 
 
1039
  return (GdkGLProc) (_procs_GLX_SGIX_pbuffer.glXGetSelectedEventSGIX);
 
1040
}
 
1041
 
 
1042
/* Get GLX_SGIX_pbuffer functions */
 
1043
GdkGL_GLX_SGIX_pbuffer *
 
1044
gdk_gl_get_GLX_SGIX_pbuffer (GdkGLConfig *glconfig)
 
1045
{
 
1046
  static gint supported = -1;
 
1047
 
 
1048
  if (supported == -1)
 
1049
    {
 
1050
      supported = gdk_x11_gl_query_glx_extension (glconfig, "GLX_SGIX_pbuffer");
 
1051
 
 
1052
      if (supported)
 
1053
        {
 
1054
          supported &= (gdk_gl_get_glXCreateGLXPbufferSGIX () != NULL);
 
1055
          supported &= (gdk_gl_get_glXDestroyGLXPbufferSGIX () != NULL);
 
1056
          supported &= (gdk_gl_get_glXQueryGLXPbufferSGIX () != NULL);
 
1057
          supported &= (gdk_gl_get_glXSelectEventSGIX () != NULL);
 
1058
          supported &= (gdk_gl_get_glXGetSelectedEventSGIX () != NULL);
 
1059
        }
 
1060
    }
 
1061
 
 
1062
  GDK_GL_NOTE (MISC,
 
1063
    g_message (" - gdk_gl_get_GLX_SGIX_pbuffer () - %s",
 
1064
               (supported) ? "supported" : "not supported"));
 
1065
 
 
1066
  if (!supported)
 
1067
    return NULL;
 
1068
 
 
1069
  return &_procs_GLX_SGIX_pbuffer;
 
1070
}
 
1071
 
 
1072
/*
 
1073
 * GLX_SGI_cushion
 
1074
 */
 
1075
 
 
1076
static GdkGL_GLX_SGI_cushion _procs_GLX_SGI_cushion = {
 
1077
  (GdkGLProc_glXCushionSGI) -1
 
1078
};
 
1079
 
 
1080
/* glXCushionSGI */
 
1081
GdkGLProc
 
1082
gdk_gl_get_glXCushionSGI (void)
 
1083
{
 
1084
  if (_procs_GLX_SGI_cushion.glXCushionSGI == (GdkGLProc_glXCushionSGI) -1)
 
1085
    _procs_GLX_SGI_cushion.glXCushionSGI =
 
1086
      (GdkGLProc_glXCushionSGI) gdk_gl_get_proc_address ("glXCushionSGI");
 
1087
 
 
1088
  GDK_GL_NOTE (MISC,
 
1089
    g_message (" - gdk_gl_get_glXCushionSGI () - %s",
 
1090
               (_procs_GLX_SGI_cushion.glXCushionSGI) ? "supported" : "not supported"));
 
1091
 
 
1092
  return (GdkGLProc) (_procs_GLX_SGI_cushion.glXCushionSGI);
 
1093
}
 
1094
 
 
1095
/* Get GLX_SGI_cushion functions */
 
1096
GdkGL_GLX_SGI_cushion *
 
1097
gdk_gl_get_GLX_SGI_cushion (GdkGLConfig *glconfig)
 
1098
{
 
1099
  static gint supported = -1;
 
1100
 
 
1101
  if (supported == -1)
 
1102
    {
 
1103
      supported = gdk_x11_gl_query_glx_extension (glconfig, "GLX_SGI_cushion");
 
1104
 
 
1105
      if (supported)
 
1106
        {
 
1107
          supported &= (gdk_gl_get_glXCushionSGI () != NULL);
 
1108
        }
 
1109
    }
 
1110
 
 
1111
  GDK_GL_NOTE (MISC,
 
1112
    g_message (" - gdk_gl_get_GLX_SGI_cushion () - %s",
 
1113
               (supported) ? "supported" : "not supported"));
 
1114
 
 
1115
  if (!supported)
 
1116
    return NULL;
 
1117
 
 
1118
  return &_procs_GLX_SGI_cushion;
 
1119
}
 
1120
 
 
1121
/*
 
1122
 * GLX_SGIX_video_resize
 
1123
 */
 
1124
 
 
1125
static GdkGL_GLX_SGIX_video_resize _procs_GLX_SGIX_video_resize = {
 
1126
  (GdkGLProc_glXBindChannelToWindowSGIX) -1,
 
1127
  (GdkGLProc_glXChannelRectSGIX) -1,
 
1128
  (GdkGLProc_glXQueryChannelRectSGIX) -1,
 
1129
  (GdkGLProc_glXQueryChannelDeltasSGIX) -1,
 
1130
  (GdkGLProc_glXChannelRectSyncSGIX) -1
 
1131
};
 
1132
 
 
1133
/* glXBindChannelToWindowSGIX */
 
1134
GdkGLProc
 
1135
gdk_gl_get_glXBindChannelToWindowSGIX (void)
 
1136
{
 
1137
  if (_procs_GLX_SGIX_video_resize.glXBindChannelToWindowSGIX == (GdkGLProc_glXBindChannelToWindowSGIX) -1)
 
1138
    _procs_GLX_SGIX_video_resize.glXBindChannelToWindowSGIX =
 
1139
      (GdkGLProc_glXBindChannelToWindowSGIX) gdk_gl_get_proc_address ("glXBindChannelToWindowSGIX");
 
1140
 
 
1141
  GDK_GL_NOTE (MISC,
 
1142
    g_message (" - gdk_gl_get_glXBindChannelToWindowSGIX () - %s",
 
1143
               (_procs_GLX_SGIX_video_resize.glXBindChannelToWindowSGIX) ? "supported" : "not supported"));
 
1144
 
 
1145
  return (GdkGLProc) (_procs_GLX_SGIX_video_resize.glXBindChannelToWindowSGIX);
 
1146
}
 
1147
 
 
1148
/* glXChannelRectSGIX */
 
1149
GdkGLProc
 
1150
gdk_gl_get_glXChannelRectSGIX (void)
 
1151
{
 
1152
  if (_procs_GLX_SGIX_video_resize.glXChannelRectSGIX == (GdkGLProc_glXChannelRectSGIX) -1)
 
1153
    _procs_GLX_SGIX_video_resize.glXChannelRectSGIX =
 
1154
      (GdkGLProc_glXChannelRectSGIX) gdk_gl_get_proc_address ("glXChannelRectSGIX");
 
1155
 
 
1156
  GDK_GL_NOTE (MISC,
 
1157
    g_message (" - gdk_gl_get_glXChannelRectSGIX () - %s",
 
1158
               (_procs_GLX_SGIX_video_resize.glXChannelRectSGIX) ? "supported" : "not supported"));
 
1159
 
 
1160
  return (GdkGLProc) (_procs_GLX_SGIX_video_resize.glXChannelRectSGIX);
 
1161
}
 
1162
 
 
1163
/* glXQueryChannelRectSGIX */
 
1164
GdkGLProc
 
1165
gdk_gl_get_glXQueryChannelRectSGIX (void)
 
1166
{
 
1167
  if (_procs_GLX_SGIX_video_resize.glXQueryChannelRectSGIX == (GdkGLProc_glXQueryChannelRectSGIX) -1)
 
1168
    _procs_GLX_SGIX_video_resize.glXQueryChannelRectSGIX =
 
1169
      (GdkGLProc_glXQueryChannelRectSGIX) gdk_gl_get_proc_address ("glXQueryChannelRectSGIX");
 
1170
 
 
1171
  GDK_GL_NOTE (MISC,
 
1172
    g_message (" - gdk_gl_get_glXQueryChannelRectSGIX () - %s",
 
1173
               (_procs_GLX_SGIX_video_resize.glXQueryChannelRectSGIX) ? "supported" : "not supported"));
 
1174
 
 
1175
  return (GdkGLProc) (_procs_GLX_SGIX_video_resize.glXQueryChannelRectSGIX);
 
1176
}
 
1177
 
 
1178
/* glXQueryChannelDeltasSGIX */
 
1179
GdkGLProc
 
1180
gdk_gl_get_glXQueryChannelDeltasSGIX (void)
 
1181
{
 
1182
  if (_procs_GLX_SGIX_video_resize.glXQueryChannelDeltasSGIX == (GdkGLProc_glXQueryChannelDeltasSGIX) -1)
 
1183
    _procs_GLX_SGIX_video_resize.glXQueryChannelDeltasSGIX =
 
1184
      (GdkGLProc_glXQueryChannelDeltasSGIX) gdk_gl_get_proc_address ("glXQueryChannelDeltasSGIX");
 
1185
 
 
1186
  GDK_GL_NOTE (MISC,
 
1187
    g_message (" - gdk_gl_get_glXQueryChannelDeltasSGIX () - %s",
 
1188
               (_procs_GLX_SGIX_video_resize.glXQueryChannelDeltasSGIX) ? "supported" : "not supported"));
 
1189
 
 
1190
  return (GdkGLProc) (_procs_GLX_SGIX_video_resize.glXQueryChannelDeltasSGIX);
 
1191
}
 
1192
 
 
1193
/* glXChannelRectSyncSGIX */
 
1194
GdkGLProc
 
1195
gdk_gl_get_glXChannelRectSyncSGIX (void)
 
1196
{
 
1197
  if (_procs_GLX_SGIX_video_resize.glXChannelRectSyncSGIX == (GdkGLProc_glXChannelRectSyncSGIX) -1)
 
1198
    _procs_GLX_SGIX_video_resize.glXChannelRectSyncSGIX =
 
1199
      (GdkGLProc_glXChannelRectSyncSGIX) gdk_gl_get_proc_address ("glXChannelRectSyncSGIX");
 
1200
 
 
1201
  GDK_GL_NOTE (MISC,
 
1202
    g_message (" - gdk_gl_get_glXChannelRectSyncSGIX () - %s",
 
1203
               (_procs_GLX_SGIX_video_resize.glXChannelRectSyncSGIX) ? "supported" : "not supported"));
 
1204
 
 
1205
  return (GdkGLProc) (_procs_GLX_SGIX_video_resize.glXChannelRectSyncSGIX);
 
1206
}
 
1207
 
 
1208
/* Get GLX_SGIX_video_resize functions */
 
1209
GdkGL_GLX_SGIX_video_resize *
 
1210
gdk_gl_get_GLX_SGIX_video_resize (GdkGLConfig *glconfig)
 
1211
{
 
1212
  static gint supported = -1;
 
1213
 
 
1214
  if (supported == -1)
 
1215
    {
 
1216
      supported = gdk_x11_gl_query_glx_extension (glconfig, "GLX_SGIX_video_resize");
 
1217
 
 
1218
      if (supported)
 
1219
        {
 
1220
          supported &= (gdk_gl_get_glXBindChannelToWindowSGIX () != NULL);
 
1221
          supported &= (gdk_gl_get_glXChannelRectSGIX () != NULL);
 
1222
          supported &= (gdk_gl_get_glXQueryChannelRectSGIX () != NULL);
 
1223
          supported &= (gdk_gl_get_glXQueryChannelDeltasSGIX () != NULL);
 
1224
          supported &= (gdk_gl_get_glXChannelRectSyncSGIX () != NULL);
 
1225
        }
 
1226
    }
 
1227
 
 
1228
  GDK_GL_NOTE (MISC,
 
1229
    g_message (" - gdk_gl_get_GLX_SGIX_video_resize () - %s",
 
1230
               (supported) ? "supported" : "not supported"));
 
1231
 
 
1232
  if (!supported)
 
1233
    return NULL;
 
1234
 
 
1235
  return &_procs_GLX_SGIX_video_resize;
 
1236
}
 
1237
 
 
1238
/*
 
1239
 * GLX_SGIX_dmbuffer
 
1240
 */
 
1241
 
 
1242
#ifdef _DM_BUFFER_H_
 
1243
 
 
1244
static GdkGL_GLX_SGIX_dmbuffer _procs_GLX_SGIX_dmbuffer = {
 
1245
  (GdkGLProc_glXAssociateDMPbufferSGIX) -1
 
1246
};
 
1247
 
 
1248
/* glXAssociateDMPbufferSGIX */
 
1249
GdkGLProc
 
1250
gdk_gl_get_glXAssociateDMPbufferSGIX (void)
 
1251
{
 
1252
  if (_procs_GLX_SGIX_dmbuffer.glXAssociateDMPbufferSGIX == (GdkGLProc_glXAssociateDMPbufferSGIX) -1)
 
1253
    _procs_GLX_SGIX_dmbuffer.glXAssociateDMPbufferSGIX =
 
1254
      (GdkGLProc_glXAssociateDMPbufferSGIX) gdk_gl_get_proc_address ("glXAssociateDMPbufferSGIX");
 
1255
 
 
1256
  GDK_GL_NOTE (MISC,
 
1257
    g_message (" - gdk_gl_get_glXAssociateDMPbufferSGIX () - %s",
 
1258
               (_procs_GLX_SGIX_dmbuffer.glXAssociateDMPbufferSGIX) ? "supported" : "not supported"));
 
1259
 
 
1260
  return (GdkGLProc) (_procs_GLX_SGIX_dmbuffer.glXAssociateDMPbufferSGIX);
 
1261
}
 
1262
 
 
1263
/* Get GLX_SGIX_dmbuffer functions */
 
1264
GdkGL_GLX_SGIX_dmbuffer *
 
1265
gdk_gl_get_GLX_SGIX_dmbuffer (GdkGLConfig *glconfig)
 
1266
{
 
1267
  static gint supported = -1;
 
1268
 
 
1269
  if (supported == -1)
 
1270
    {
 
1271
      supported = gdk_x11_gl_query_glx_extension (glconfig, "GLX_SGIX_dmbuffer");
 
1272
 
 
1273
      if (supported)
 
1274
        {
 
1275
          supported &= (gdk_gl_get_glXAssociateDMPbufferSGIX () != NULL);
 
1276
        }
 
1277
    }
 
1278
 
 
1279
  GDK_GL_NOTE (MISC,
 
1280
    g_message (" - gdk_gl_get_GLX_SGIX_dmbuffer () - %s",
 
1281
               (supported) ? "supported" : "not supported"));
 
1282
 
 
1283
  if (!supported)
 
1284
    return NULL;
 
1285
 
 
1286
  return &_procs_GLX_SGIX_dmbuffer;
 
1287
}
 
1288
 
 
1289
#endif /* _DM_BUFFER_H_ */
 
1290
 
 
1291
/*
 
1292
 * GLX_SGIX_swap_group
 
1293
 */
 
1294
 
 
1295
static GdkGL_GLX_SGIX_swap_group _procs_GLX_SGIX_swap_group = {
 
1296
  (GdkGLProc_glXJoinSwapGroupSGIX) -1
 
1297
};
 
1298
 
 
1299
/* glXJoinSwapGroupSGIX */
 
1300
GdkGLProc
 
1301
gdk_gl_get_glXJoinSwapGroupSGIX (void)
 
1302
{
 
1303
  if (_procs_GLX_SGIX_swap_group.glXJoinSwapGroupSGIX == (GdkGLProc_glXJoinSwapGroupSGIX) -1)
 
1304
    _procs_GLX_SGIX_swap_group.glXJoinSwapGroupSGIX =
 
1305
      (GdkGLProc_glXJoinSwapGroupSGIX) gdk_gl_get_proc_address ("glXJoinSwapGroupSGIX");
 
1306
 
 
1307
  GDK_GL_NOTE (MISC,
 
1308
    g_message (" - gdk_gl_get_glXJoinSwapGroupSGIX () - %s",
 
1309
               (_procs_GLX_SGIX_swap_group.glXJoinSwapGroupSGIX) ? "supported" : "not supported"));
 
1310
 
 
1311
  return (GdkGLProc) (_procs_GLX_SGIX_swap_group.glXJoinSwapGroupSGIX);
 
1312
}
 
1313
 
 
1314
/* Get GLX_SGIX_swap_group functions */
 
1315
GdkGL_GLX_SGIX_swap_group *
 
1316
gdk_gl_get_GLX_SGIX_swap_group (GdkGLConfig *glconfig)
 
1317
{
 
1318
  static gint supported = -1;
 
1319
 
 
1320
  if (supported == -1)
 
1321
    {
 
1322
      supported = gdk_x11_gl_query_glx_extension (glconfig, "GLX_SGIX_swap_group");
 
1323
 
 
1324
      if (supported)
 
1325
        {
 
1326
          supported &= (gdk_gl_get_glXJoinSwapGroupSGIX () != NULL);
 
1327
        }
 
1328
    }
 
1329
 
 
1330
  GDK_GL_NOTE (MISC,
 
1331
    g_message (" - gdk_gl_get_GLX_SGIX_swap_group () - %s",
 
1332
               (supported) ? "supported" : "not supported"));
 
1333
 
 
1334
  if (!supported)
 
1335
    return NULL;
 
1336
 
 
1337
  return &_procs_GLX_SGIX_swap_group;
 
1338
}
 
1339
 
 
1340
/*
 
1341
 * GLX_SGIX_swap_barrier
 
1342
 */
 
1343
 
 
1344
static GdkGL_GLX_SGIX_swap_barrier _procs_GLX_SGIX_swap_barrier = {
 
1345
  (GdkGLProc_glXBindSwapBarrierSGIX) -1,
 
1346
  (GdkGLProc_glXQueryMaxSwapBarriersSGIX) -1
 
1347
};
 
1348
 
 
1349
/* glXBindSwapBarrierSGIX */
 
1350
GdkGLProc
 
1351
gdk_gl_get_glXBindSwapBarrierSGIX (void)
 
1352
{
 
1353
  if (_procs_GLX_SGIX_swap_barrier.glXBindSwapBarrierSGIX == (GdkGLProc_glXBindSwapBarrierSGIX) -1)
 
1354
    _procs_GLX_SGIX_swap_barrier.glXBindSwapBarrierSGIX =
 
1355
      (GdkGLProc_glXBindSwapBarrierSGIX) gdk_gl_get_proc_address ("glXBindSwapBarrierSGIX");
 
1356
 
 
1357
  GDK_GL_NOTE (MISC,
 
1358
    g_message (" - gdk_gl_get_glXBindSwapBarrierSGIX () - %s",
 
1359
               (_procs_GLX_SGIX_swap_barrier.glXBindSwapBarrierSGIX) ? "supported" : "not supported"));
 
1360
 
 
1361
  return (GdkGLProc) (_procs_GLX_SGIX_swap_barrier.glXBindSwapBarrierSGIX);
 
1362
}
 
1363
 
 
1364
/* glXQueryMaxSwapBarriersSGIX */
 
1365
GdkGLProc
 
1366
gdk_gl_get_glXQueryMaxSwapBarriersSGIX (void)
 
1367
{
 
1368
  if (_procs_GLX_SGIX_swap_barrier.glXQueryMaxSwapBarriersSGIX == (GdkGLProc_glXQueryMaxSwapBarriersSGIX) -1)
 
1369
    _procs_GLX_SGIX_swap_barrier.glXQueryMaxSwapBarriersSGIX =
 
1370
      (GdkGLProc_glXQueryMaxSwapBarriersSGIX) gdk_gl_get_proc_address ("glXQueryMaxSwapBarriersSGIX");
 
1371
 
 
1372
  GDK_GL_NOTE (MISC,
 
1373
    g_message (" - gdk_gl_get_glXQueryMaxSwapBarriersSGIX () - %s",
 
1374
               (_procs_GLX_SGIX_swap_barrier.glXQueryMaxSwapBarriersSGIX) ? "supported" : "not supported"));
 
1375
 
 
1376
  return (GdkGLProc) (_procs_GLX_SGIX_swap_barrier.glXQueryMaxSwapBarriersSGIX);
 
1377
}
 
1378
 
 
1379
/* Get GLX_SGIX_swap_barrier functions */
 
1380
GdkGL_GLX_SGIX_swap_barrier *
 
1381
gdk_gl_get_GLX_SGIX_swap_barrier (GdkGLConfig *glconfig)
 
1382
{
 
1383
  static gint supported = -1;
 
1384
 
 
1385
  if (supported == -1)
 
1386
    {
 
1387
      supported = gdk_x11_gl_query_glx_extension (glconfig, "GLX_SGIX_swap_barrier");
 
1388
 
 
1389
      if (supported)
 
1390
        {
 
1391
          supported &= (gdk_gl_get_glXBindSwapBarrierSGIX () != NULL);
 
1392
          supported &= (gdk_gl_get_glXQueryMaxSwapBarriersSGIX () != NULL);
 
1393
        }
 
1394
    }
 
1395
 
 
1396
  GDK_GL_NOTE (MISC,
 
1397
    g_message (" - gdk_gl_get_GLX_SGIX_swap_barrier () - %s",
 
1398
               (supported) ? "supported" : "not supported"));
 
1399
 
 
1400
  if (!supported)
 
1401
    return NULL;
 
1402
 
 
1403
  return &_procs_GLX_SGIX_swap_barrier;
 
1404
}
 
1405
 
 
1406
/*
 
1407
 * GLX_SUN_get_transparent_index
 
1408
 */
 
1409
 
 
1410
static GdkGL_GLX_SUN_get_transparent_index _procs_GLX_SUN_get_transparent_index = {
 
1411
  (GdkGLProc_glXGetTransparentIndexSUN) -1
 
1412
};
 
1413
 
 
1414
/* glXGetTransparentIndexSUN */
 
1415
GdkGLProc
 
1416
gdk_gl_get_glXGetTransparentIndexSUN (void)
 
1417
{
 
1418
  if (_procs_GLX_SUN_get_transparent_index.glXGetTransparentIndexSUN == (GdkGLProc_glXGetTransparentIndexSUN) -1)
 
1419
    _procs_GLX_SUN_get_transparent_index.glXGetTransparentIndexSUN =
 
1420
      (GdkGLProc_glXGetTransparentIndexSUN) gdk_gl_get_proc_address ("glXGetTransparentIndexSUN");
 
1421
 
 
1422
  GDK_GL_NOTE (MISC,
 
1423
    g_message (" - gdk_gl_get_glXGetTransparentIndexSUN () - %s",
 
1424
               (_procs_GLX_SUN_get_transparent_index.glXGetTransparentIndexSUN) ? "supported" : "not supported"));
 
1425
 
 
1426
  return (GdkGLProc) (_procs_GLX_SUN_get_transparent_index.glXGetTransparentIndexSUN);
 
1427
}
 
1428
 
 
1429
/* Get GLX_SUN_get_transparent_index functions */
 
1430
GdkGL_GLX_SUN_get_transparent_index *
 
1431
gdk_gl_get_GLX_SUN_get_transparent_index (GdkGLConfig *glconfig)
 
1432
{
 
1433
  static gint supported = -1;
 
1434
 
 
1435
  if (supported == -1)
 
1436
    {
 
1437
      supported = gdk_x11_gl_query_glx_extension (glconfig, "GLX_SUN_get_transparent_index");
 
1438
 
 
1439
      if (supported)
 
1440
        {
 
1441
          supported &= (gdk_gl_get_glXGetTransparentIndexSUN () != NULL);
 
1442
        }
 
1443
    }
 
1444
 
 
1445
  GDK_GL_NOTE (MISC,
 
1446
    g_message (" - gdk_gl_get_GLX_SUN_get_transparent_index () - %s",
 
1447
               (supported) ? "supported" : "not supported"));
 
1448
 
 
1449
  if (!supported)
 
1450
    return NULL;
 
1451
 
 
1452
  return &_procs_GLX_SUN_get_transparent_index;
 
1453
}
 
1454
 
 
1455
/*
 
1456
 * GLX_MESA_copy_sub_buffer
 
1457
 */
 
1458
 
 
1459
static GdkGL_GLX_MESA_copy_sub_buffer _procs_GLX_MESA_copy_sub_buffer = {
 
1460
  (GdkGLProc_glXCopySubBufferMESA) -1
 
1461
};
 
1462
 
 
1463
/* glXCopySubBufferMESA */
 
1464
GdkGLProc
 
1465
gdk_gl_get_glXCopySubBufferMESA (void)
 
1466
{
 
1467
  if (_procs_GLX_MESA_copy_sub_buffer.glXCopySubBufferMESA == (GdkGLProc_glXCopySubBufferMESA) -1)
 
1468
    _procs_GLX_MESA_copy_sub_buffer.glXCopySubBufferMESA =
 
1469
      (GdkGLProc_glXCopySubBufferMESA) gdk_gl_get_proc_address ("glXCopySubBufferMESA");
 
1470
 
 
1471
  GDK_GL_NOTE (MISC,
 
1472
    g_message (" - gdk_gl_get_glXCopySubBufferMESA () - %s",
 
1473
               (_procs_GLX_MESA_copy_sub_buffer.glXCopySubBufferMESA) ? "supported" : "not supported"));
 
1474
 
 
1475
  return (GdkGLProc) (_procs_GLX_MESA_copy_sub_buffer.glXCopySubBufferMESA);
 
1476
}
 
1477
 
 
1478
/* Get GLX_MESA_copy_sub_buffer functions */
 
1479
GdkGL_GLX_MESA_copy_sub_buffer *
 
1480
gdk_gl_get_GLX_MESA_copy_sub_buffer (GdkGLConfig *glconfig)
 
1481
{
 
1482
  static gint supported = -1;
 
1483
 
 
1484
  if (supported == -1)
 
1485
    {
 
1486
      supported = gdk_x11_gl_query_glx_extension (glconfig, "GLX_MESA_copy_sub_buffer");
 
1487
 
 
1488
      if (supported)
 
1489
        {
 
1490
          supported &= (gdk_gl_get_glXCopySubBufferMESA () != NULL);
 
1491
        }
 
1492
    }
 
1493
 
 
1494
  GDK_GL_NOTE (MISC,
 
1495
    g_message (" - gdk_gl_get_GLX_MESA_copy_sub_buffer () - %s",
 
1496
               (supported) ? "supported" : "not supported"));
 
1497
 
 
1498
  if (!supported)
 
1499
    return NULL;
 
1500
 
 
1501
  return &_procs_GLX_MESA_copy_sub_buffer;
 
1502
}
 
1503
 
 
1504
/*
 
1505
 * GLX_MESA_pixmap_colormap
 
1506
 */
 
1507
 
 
1508
static GdkGL_GLX_MESA_pixmap_colormap _procs_GLX_MESA_pixmap_colormap = {
 
1509
  (GdkGLProc_glXCreateGLXPixmapMESA) -1
 
1510
};
 
1511
 
 
1512
/* glXCreateGLXPixmapMESA */
 
1513
GdkGLProc
 
1514
gdk_gl_get_glXCreateGLXPixmapMESA (void)
 
1515
{
 
1516
  if (_procs_GLX_MESA_pixmap_colormap.glXCreateGLXPixmapMESA == (GdkGLProc_glXCreateGLXPixmapMESA) -1)
 
1517
    _procs_GLX_MESA_pixmap_colormap.glXCreateGLXPixmapMESA =
 
1518
      (GdkGLProc_glXCreateGLXPixmapMESA) gdk_gl_get_proc_address ("glXCreateGLXPixmapMESA");
 
1519
 
 
1520
  GDK_GL_NOTE (MISC,
 
1521
    g_message (" - gdk_gl_get_glXCreateGLXPixmapMESA () - %s",
 
1522
               (_procs_GLX_MESA_pixmap_colormap.glXCreateGLXPixmapMESA) ? "supported" : "not supported"));
 
1523
 
 
1524
  return (GdkGLProc) (_procs_GLX_MESA_pixmap_colormap.glXCreateGLXPixmapMESA);
 
1525
}
 
1526
 
 
1527
/* Get GLX_MESA_pixmap_colormap functions */
 
1528
GdkGL_GLX_MESA_pixmap_colormap *
 
1529
gdk_gl_get_GLX_MESA_pixmap_colormap (GdkGLConfig *glconfig)
 
1530
{
 
1531
  static gint supported = -1;
 
1532
 
 
1533
  if (supported == -1)
 
1534
    {
 
1535
      supported = gdk_x11_gl_query_glx_extension (glconfig, "GLX_MESA_pixmap_colormap");
 
1536
 
 
1537
      if (supported)
 
1538
        {
 
1539
          supported &= (gdk_gl_get_glXCreateGLXPixmapMESA () != NULL);
 
1540
        }
 
1541
    }
 
1542
 
 
1543
  GDK_GL_NOTE (MISC,
 
1544
    g_message (" - gdk_gl_get_GLX_MESA_pixmap_colormap () - %s",
 
1545
               (supported) ? "supported" : "not supported"));
 
1546
 
 
1547
  if (!supported)
 
1548
    return NULL;
 
1549
 
 
1550
  return &_procs_GLX_MESA_pixmap_colormap;
 
1551
}
 
1552
 
 
1553
/*
 
1554
 * GLX_MESA_release_buffers
 
1555
 */
 
1556
 
 
1557
static GdkGL_GLX_MESA_release_buffers _procs_GLX_MESA_release_buffers = {
 
1558
  (GdkGLProc_glXReleaseBuffersMESA) -1
 
1559
};
 
1560
 
 
1561
/* glXReleaseBuffersMESA */
 
1562
GdkGLProc
 
1563
gdk_gl_get_glXReleaseBuffersMESA (void)
 
1564
{
 
1565
  if (_procs_GLX_MESA_release_buffers.glXReleaseBuffersMESA == (GdkGLProc_glXReleaseBuffersMESA) -1)
 
1566
    _procs_GLX_MESA_release_buffers.glXReleaseBuffersMESA =
 
1567
      (GdkGLProc_glXReleaseBuffersMESA) gdk_gl_get_proc_address ("glXReleaseBuffersMESA");
 
1568
 
 
1569
  GDK_GL_NOTE (MISC,
 
1570
    g_message (" - gdk_gl_get_glXReleaseBuffersMESA () - %s",
 
1571
               (_procs_GLX_MESA_release_buffers.glXReleaseBuffersMESA) ? "supported" : "not supported"));
 
1572
 
 
1573
  return (GdkGLProc) (_procs_GLX_MESA_release_buffers.glXReleaseBuffersMESA);
 
1574
}
 
1575
 
 
1576
/* Get GLX_MESA_release_buffers functions */
 
1577
GdkGL_GLX_MESA_release_buffers *
 
1578
gdk_gl_get_GLX_MESA_release_buffers (GdkGLConfig *glconfig)
 
1579
{
 
1580
  static gint supported = -1;
 
1581
 
 
1582
  if (supported == -1)
 
1583
    {
 
1584
      supported = gdk_x11_gl_query_glx_extension (glconfig, "GLX_MESA_release_buffers");
 
1585
 
 
1586
      if (supported)
 
1587
        {
 
1588
          supported &= (gdk_gl_get_glXReleaseBuffersMESA () != NULL);
 
1589
        }
 
1590
    }
 
1591
 
 
1592
  GDK_GL_NOTE (MISC,
 
1593
    g_message (" - gdk_gl_get_GLX_MESA_release_buffers () - %s",
 
1594
               (supported) ? "supported" : "not supported"));
 
1595
 
 
1596
  if (!supported)
 
1597
    return NULL;
 
1598
 
 
1599
  return &_procs_GLX_MESA_release_buffers;
 
1600
}
 
1601
 
 
1602
/*
 
1603
 * GLX_MESA_set_3dfx_mode
 
1604
 */
 
1605
 
 
1606
static GdkGL_GLX_MESA_set_3dfx_mode _procs_GLX_MESA_set_3dfx_mode = {
 
1607
  (GdkGLProc_glXSet3DfxModeMESA) -1
 
1608
};
 
1609
 
 
1610
/* glXSet3DfxModeMESA */
 
1611
GdkGLProc
 
1612
gdk_gl_get_glXSet3DfxModeMESA (void)
 
1613
{
 
1614
  if (_procs_GLX_MESA_set_3dfx_mode.glXSet3DfxModeMESA == (GdkGLProc_glXSet3DfxModeMESA) -1)
 
1615
    _procs_GLX_MESA_set_3dfx_mode.glXSet3DfxModeMESA =
 
1616
      (GdkGLProc_glXSet3DfxModeMESA) gdk_gl_get_proc_address ("glXSet3DfxModeMESA");
 
1617
 
 
1618
  GDK_GL_NOTE (MISC,
 
1619
    g_message (" - gdk_gl_get_glXSet3DfxModeMESA () - %s",
 
1620
               (_procs_GLX_MESA_set_3dfx_mode.glXSet3DfxModeMESA) ? "supported" : "not supported"));
 
1621
 
 
1622
  return (GdkGLProc) (_procs_GLX_MESA_set_3dfx_mode.glXSet3DfxModeMESA);
 
1623
}
 
1624
 
 
1625
/* Get GLX_MESA_set_3dfx_mode functions */
 
1626
GdkGL_GLX_MESA_set_3dfx_mode *
 
1627
gdk_gl_get_GLX_MESA_set_3dfx_mode (GdkGLConfig *glconfig)
 
1628
{
 
1629
  static gint supported = -1;
 
1630
 
 
1631
  if (supported == -1)
 
1632
    {
 
1633
      supported = gdk_x11_gl_query_glx_extension (glconfig, "GLX_MESA_set_3dfx_mode");
 
1634
 
 
1635
      if (supported)
 
1636
        {
 
1637
          supported &= (gdk_gl_get_glXSet3DfxModeMESA () != NULL);
 
1638
        }
 
1639
    }
 
1640
 
 
1641
  GDK_GL_NOTE (MISC,
 
1642
    g_message (" - gdk_gl_get_GLX_MESA_set_3dfx_mode () - %s",
 
1643
               (supported) ? "supported" : "not supported"));
 
1644
 
 
1645
  if (!supported)
 
1646
    return NULL;
 
1647
 
 
1648
  return &_procs_GLX_MESA_set_3dfx_mode;
 
1649
}
 
1650
 
 
1651
/*
 
1652
 * GLX_OML_sync_control
 
1653
 */
 
1654
 
 
1655
static GdkGL_GLX_OML_sync_control _procs_GLX_OML_sync_control = {
 
1656
  (GdkGLProc_glXGetSyncValuesOML) -1,
 
1657
  (GdkGLProc_glXGetMscRateOML) -1,
 
1658
  (GdkGLProc_glXSwapBuffersMscOML) -1,
 
1659
  (GdkGLProc_glXWaitForMscOML) -1,
 
1660
  (GdkGLProc_glXWaitForSbcOML) -1
 
1661
};
 
1662
 
 
1663
/* glXGetSyncValuesOML */
 
1664
GdkGLProc
 
1665
gdk_gl_get_glXGetSyncValuesOML (void)
 
1666
{
 
1667
  if (_procs_GLX_OML_sync_control.glXGetSyncValuesOML == (GdkGLProc_glXGetSyncValuesOML) -1)
 
1668
    _procs_GLX_OML_sync_control.glXGetSyncValuesOML =
 
1669
      (GdkGLProc_glXGetSyncValuesOML) gdk_gl_get_proc_address ("glXGetSyncValuesOML");
 
1670
 
 
1671
  GDK_GL_NOTE (MISC,
 
1672
    g_message (" - gdk_gl_get_glXGetSyncValuesOML () - %s",
 
1673
               (_procs_GLX_OML_sync_control.glXGetSyncValuesOML) ? "supported" : "not supported"));
 
1674
 
 
1675
  return (GdkGLProc) (_procs_GLX_OML_sync_control.glXGetSyncValuesOML);
 
1676
}
 
1677
 
 
1678
/* glXGetMscRateOML */
 
1679
GdkGLProc
 
1680
gdk_gl_get_glXGetMscRateOML (void)
 
1681
{
 
1682
  if (_procs_GLX_OML_sync_control.glXGetMscRateOML == (GdkGLProc_glXGetMscRateOML) -1)
 
1683
    _procs_GLX_OML_sync_control.glXGetMscRateOML =
 
1684
      (GdkGLProc_glXGetMscRateOML) gdk_gl_get_proc_address ("glXGetMscRateOML");
 
1685
 
 
1686
  GDK_GL_NOTE (MISC,
 
1687
    g_message (" - gdk_gl_get_glXGetMscRateOML () - %s",
 
1688
               (_procs_GLX_OML_sync_control.glXGetMscRateOML) ? "supported" : "not supported"));
 
1689
 
 
1690
  return (GdkGLProc) (_procs_GLX_OML_sync_control.glXGetMscRateOML);
 
1691
}
 
1692
 
 
1693
/* glXSwapBuffersMscOML */
 
1694
GdkGLProc
 
1695
gdk_gl_get_glXSwapBuffersMscOML (void)
 
1696
{
 
1697
  if (_procs_GLX_OML_sync_control.glXSwapBuffersMscOML == (GdkGLProc_glXSwapBuffersMscOML) -1)
 
1698
    _procs_GLX_OML_sync_control.glXSwapBuffersMscOML =
 
1699
      (GdkGLProc_glXSwapBuffersMscOML) gdk_gl_get_proc_address ("glXSwapBuffersMscOML");
 
1700
 
 
1701
  GDK_GL_NOTE (MISC,
 
1702
    g_message (" - gdk_gl_get_glXSwapBuffersMscOML () - %s",
 
1703
               (_procs_GLX_OML_sync_control.glXSwapBuffersMscOML) ? "supported" : "not supported"));
 
1704
 
 
1705
  return (GdkGLProc) (_procs_GLX_OML_sync_control.glXSwapBuffersMscOML);
 
1706
}
 
1707
 
 
1708
/* glXWaitForMscOML */
 
1709
GdkGLProc
 
1710
gdk_gl_get_glXWaitForMscOML (void)
 
1711
{
 
1712
  if (_procs_GLX_OML_sync_control.glXWaitForMscOML == (GdkGLProc_glXWaitForMscOML) -1)
 
1713
    _procs_GLX_OML_sync_control.glXWaitForMscOML =
 
1714
      (GdkGLProc_glXWaitForMscOML) gdk_gl_get_proc_address ("glXWaitForMscOML");
 
1715
 
 
1716
  GDK_GL_NOTE (MISC,
 
1717
    g_message (" - gdk_gl_get_glXWaitForMscOML () - %s",
 
1718
               (_procs_GLX_OML_sync_control.glXWaitForMscOML) ? "supported" : "not supported"));
 
1719
 
 
1720
  return (GdkGLProc) (_procs_GLX_OML_sync_control.glXWaitForMscOML);
 
1721
}
 
1722
 
 
1723
/* glXWaitForSbcOML */
 
1724
GdkGLProc
 
1725
gdk_gl_get_glXWaitForSbcOML (void)
 
1726
{
 
1727
  if (_procs_GLX_OML_sync_control.glXWaitForSbcOML == (GdkGLProc_glXWaitForSbcOML) -1)
 
1728
    _procs_GLX_OML_sync_control.glXWaitForSbcOML =
 
1729
      (GdkGLProc_glXWaitForSbcOML) gdk_gl_get_proc_address ("glXWaitForSbcOML");
 
1730
 
 
1731
  GDK_GL_NOTE (MISC,
 
1732
    g_message (" - gdk_gl_get_glXWaitForSbcOML () - %s",
 
1733
               (_procs_GLX_OML_sync_control.glXWaitForSbcOML) ? "supported" : "not supported"));
 
1734
 
 
1735
  return (GdkGLProc) (_procs_GLX_OML_sync_control.glXWaitForSbcOML);
 
1736
}
 
1737
 
 
1738
/* Get GLX_OML_sync_control functions */
 
1739
GdkGL_GLX_OML_sync_control *
 
1740
gdk_gl_get_GLX_OML_sync_control (GdkGLConfig *glconfig)
 
1741
{
 
1742
  static gint supported = -1;
 
1743
 
 
1744
  if (supported == -1)
 
1745
    {
 
1746
      supported = gdk_x11_gl_query_glx_extension (glconfig, "GLX_OML_sync_control");
 
1747
 
 
1748
      if (supported)
 
1749
        {
 
1750
          supported &= (gdk_gl_get_glXGetSyncValuesOML () != NULL);
 
1751
          supported &= (gdk_gl_get_glXGetMscRateOML () != NULL);
 
1752
          supported &= (gdk_gl_get_glXSwapBuffersMscOML () != NULL);
 
1753
          supported &= (gdk_gl_get_glXWaitForMscOML () != NULL);
 
1754
          supported &= (gdk_gl_get_glXWaitForSbcOML () != NULL);
 
1755
        }
 
1756
    }
 
1757
 
 
1758
  GDK_GL_NOTE (MISC,
 
1759
    g_message (" - gdk_gl_get_GLX_OML_sync_control () - %s",
 
1760
               (supported) ? "supported" : "not supported"));
 
1761
 
 
1762
  if (!supported)
 
1763
    return NULL;
 
1764
 
 
1765
  return &_procs_GLX_OML_sync_control;
 
1766
}
 
1767
 
 
1768
/*
 
1769
 * GLX_MESA_agp_offset
 
1770
 */
 
1771
 
 
1772
static GdkGL_GLX_MESA_agp_offset _procs_GLX_MESA_agp_offset = {
 
1773
  (GdkGLProc_glXGetAGPOffsetMESA) -1
 
1774
};
 
1775
 
 
1776
/* glXGetAGPOffsetMESA */
 
1777
GdkGLProc
 
1778
gdk_gl_get_glXGetAGPOffsetMESA (void)
 
1779
{
 
1780
  if (_procs_GLX_MESA_agp_offset.glXGetAGPOffsetMESA == (GdkGLProc_glXGetAGPOffsetMESA) -1)
 
1781
    _procs_GLX_MESA_agp_offset.glXGetAGPOffsetMESA =
 
1782
      (GdkGLProc_glXGetAGPOffsetMESA) gdk_gl_get_proc_address ("glXGetAGPOffsetMESA");
 
1783
 
 
1784
  GDK_GL_NOTE (MISC,
 
1785
    g_message (" - gdk_gl_get_glXGetAGPOffsetMESA () - %s",
 
1786
               (_procs_GLX_MESA_agp_offset.glXGetAGPOffsetMESA) ? "supported" : "not supported"));
 
1787
 
 
1788
  return (GdkGLProc) (_procs_GLX_MESA_agp_offset.glXGetAGPOffsetMESA);
 
1789
}
 
1790
 
 
1791
/* Get GLX_MESA_agp_offset functions */
 
1792
GdkGL_GLX_MESA_agp_offset *
 
1793
gdk_gl_get_GLX_MESA_agp_offset (GdkGLConfig *glconfig)
 
1794
{
 
1795
  static gint supported = -1;
 
1796
 
 
1797
  if (supported == -1)
 
1798
    {
 
1799
      supported = gdk_x11_gl_query_glx_extension (glconfig, "GLX_MESA_agp_offset");
 
1800
 
 
1801
      if (supported)
 
1802
        {
 
1803
          supported &= (gdk_gl_get_glXGetAGPOffsetMESA () != NULL);
 
1804
        }
 
1805
    }
 
1806
 
 
1807
  GDK_GL_NOTE (MISC,
 
1808
    g_message (" - gdk_gl_get_GLX_MESA_agp_offset () - %s",
 
1809
               (supported) ? "supported" : "not supported"));
 
1810
 
 
1811
  if (!supported)
 
1812
    return NULL;
 
1813
 
 
1814
  return &_procs_GLX_MESA_agp_offset;
 
1815
}
 
1816
 
 
1817
/*
 
1818
 * GLX_NV_vertex_array_range
 
1819
 */
 
1820
 
 
1821
static GdkGL_GLX_NV_vertex_array_range _procs_GLX_NV_vertex_array_range = {
 
1822
  (GdkGLProc_glXAllocateMemoryNV) -1,
 
1823
  (GdkGLProc_glXFreeMemoryNV) -1
 
1824
};
 
1825
 
 
1826
/* glXAllocateMemoryNV */
 
1827
GdkGLProc
 
1828
gdk_gl_get_glXAllocateMemoryNV (void)
 
1829
{
 
1830
  if (_procs_GLX_NV_vertex_array_range.glXAllocateMemoryNV == (GdkGLProc_glXAllocateMemoryNV) -1)
 
1831
    _procs_GLX_NV_vertex_array_range.glXAllocateMemoryNV =
 
1832
      (GdkGLProc_glXAllocateMemoryNV) gdk_gl_get_proc_address ("glXAllocateMemoryNV");
 
1833
 
 
1834
  GDK_GL_NOTE (MISC,
 
1835
    g_message (" - gdk_gl_get_glXAllocateMemoryNV () - %s",
 
1836
               (_procs_GLX_NV_vertex_array_range.glXAllocateMemoryNV) ? "supported" : "not supported"));
 
1837
 
 
1838
  return (GdkGLProc) (_procs_GLX_NV_vertex_array_range.glXAllocateMemoryNV);
 
1839
}
 
1840
 
 
1841
/* glXFreeMemoryNV */
 
1842
GdkGLProc
 
1843
gdk_gl_get_glXFreeMemoryNV (void)
 
1844
{
 
1845
  if (_procs_GLX_NV_vertex_array_range.glXFreeMemoryNV == (GdkGLProc_glXFreeMemoryNV) -1)
 
1846
    _procs_GLX_NV_vertex_array_range.glXFreeMemoryNV =
 
1847
      (GdkGLProc_glXFreeMemoryNV) gdk_gl_get_proc_address ("glXFreeMemoryNV");
 
1848
 
 
1849
  GDK_GL_NOTE (MISC,
 
1850
    g_message (" - gdk_gl_get_glXFreeMemoryNV () - %s",
 
1851
               (_procs_GLX_NV_vertex_array_range.glXFreeMemoryNV) ? "supported" : "not supported"));
 
1852
 
 
1853
  return (GdkGLProc) (_procs_GLX_NV_vertex_array_range.glXFreeMemoryNV);
 
1854
}
 
1855
 
 
1856
/* Get GLX_NV_vertex_array_range functions */
 
1857
GdkGL_GLX_NV_vertex_array_range *
 
1858
gdk_gl_get_GLX_NV_vertex_array_range (GdkGLConfig *glconfig)
 
1859
{
 
1860
  static gint supported = -1;
 
1861
 
 
1862
  if (supported == -1)
 
1863
    {
 
1864
      supported = gdk_x11_gl_query_glx_extension (glconfig, "GLX_NV_vertex_array_range");
 
1865
 
 
1866
      if (supported)
 
1867
        {
 
1868
          supported &= (gdk_gl_get_glXAllocateMemoryNV () != NULL);
 
1869
          supported &= (gdk_gl_get_glXFreeMemoryNV () != NULL);
 
1870
        }
 
1871
    }
 
1872
 
 
1873
  GDK_GL_NOTE (MISC,
 
1874
    g_message (" - gdk_gl_get_GLX_NV_vertex_array_range () - %s",
 
1875
               (supported) ? "supported" : "not supported"));
 
1876
 
 
1877
  if (!supported)
 
1878
    return NULL;
 
1879
 
 
1880
  return &_procs_GLX_NV_vertex_array_range;
 
1881
}
 
1882