This should make most linux-solo drivers work again. Mainly a fix
[mesa.git] / src / mesa / glapi / glapi.h
1
2 /*
3 * Mesa 3-D graphics library
4 * Version: 3.5
5 *
6 * Copyright (C) 1999-2001 Brian Paul All Rights Reserved.
7 *
8 * Permission is hereby granted, free of charge, to any person obtaining a
9 * copy of this software and associated documentation files (the "Software"),
10 * to deal in the Software without restriction, including without limitation
11 * the rights to use, copy, modify, merge, publish, distribute, sublicense,
12 * and/or sell copies of the Software, and to permit persons to whom the
13 * Software is furnished to do so, subject to the following conditions:
14 *
15 * The above copyright notice and this permission notice shall be included
16 * in all copies or substantial portions of the Software.
17 *
18 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
19 * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
20 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
21 * BRIAN PAUL BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
22 * AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
23 * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
24 */
25
26
27 #ifndef _GLAPI_H
28 #define _GLAPI_H
29
30
31 #include "GL/gl.h"
32
33 struct _glapi_table;
34
35 typedef void (*_glapi_warning_func)(void *ctx, const char *str, ...);
36
37
38 extern void *_glapi_Context;
39
40 extern struct _glapi_table *_glapi_Dispatch;
41
42
43 extern void
44 _glapi_noop_enable_warnings(GLboolean enable);
45
46 extern void
47 _glapi_set_warning_func(_glapi_warning_func func);
48
49 extern void
50 _glapi_check_multithread(void);
51
52
53 extern void
54 _glapi_set_context(void *context);
55
56
57 extern void *
58 _glapi_get_context(void);
59
60
61 extern void
62 _glapi_set_dispatch(struct _glapi_table *dispatch);
63
64
65 extern struct _glapi_table *
66 _glapi_get_dispatch(void);
67
68
69 extern int
70 _glapi_begin_dispatch_override(struct _glapi_table *override);
71
72
73 extern void
74 _glapi_end_dispatch_override(int layer);
75
76
77 struct _glapi_table *
78 _glapi_get_override_dispatch(int layer);
79
80
81 extern GLuint
82 _glapi_get_dispatch_table_size(void);
83
84
85 extern const char *
86 _glapi_get_version(void);
87
88
89 extern void
90 _glapi_check_table(const struct _glapi_table *table);
91
92
93 extern GLboolean
94 _glapi_add_entrypoint(const char *funcName, GLuint offset);
95
96
97 extern GLint
98 _glapi_get_proc_offset(const char *funcName);
99
100
101 extern const GLvoid *
102 _glapi_get_proc_address(const char *funcName);
103
104
105 extern const char *
106 _glapi_get_proc_name(GLuint offset);
107
108
109 #endif