2 Copyright (C) 1996-1997 Id Software, Inc.
4 This program is free software; you can redistribute it and/or
5 modify it under the terms of the GNU General Public License
6 as published by the Free Software Foundation; either version 2
7 of the License, or (at your option) any later version.
9 This program 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.
13 See the GNU General Public License for more details.
15 You should have received a copy of the GNU General Public License
16 along with this program; if not, write to the Free Software
17 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
20 // disable data conversion warnings
23 //#pragma warning(disable : 4244) // MIPS
24 //#pragma warning(disable : 4136) // X86
25 //#pragma warning(disable : 4051) // ALPHA
26 #pragma warning(disable : 4244) // LordHavoc: MSVC++ 4 x86, double/float
27 #pragma warning(disable : 4305) // LordHavoc: MSVC++ 6 x86, double/float
28 #pragma warning(disable : 4018) // LordHavoc: MSVC++ 4 x86, signed/unsigned mismatch
33 #define strcasecmp stricmp
34 #define strncasecmp strnicmp
40 extern qboolean isG200;
41 extern qboolean isRagePro;
43 extern void GL_BeginRendering (int *x, int *y, int *width, int *height);
44 extern void GL_EndRendering (void);
46 extern float gldepthmin, gldepthmax;
57 //====================================================
59 extern const char *gl_vendor;
60 extern const char *gl_renderer;
61 extern const char *gl_version;
62 extern const char *gl_extensions;
65 #define APIENTRY /* */
68 // for platforms (wgl) that do not use GLAPIENTRY
70 #define GLAPIENTRY APIENTRY
73 // GL_ARB_multitexture
74 extern int gl_mtexable;
75 extern void (GLAPIENTRY *qglMultiTexCoord2f) (GLenum, GLfloat, GLfloat);
76 extern void (GLAPIENTRY *qglActiveTexture) (GLenum);
77 extern void (GLAPIENTRY *qglClientActiveTexture) (GLenum);
78 #ifndef GL_ACTIVE_TEXTURE_ARB
79 #define GL_ACTIVE_TEXTURE_ARB 0x84E0
80 #define GL_CLIENT_ACTIVE_TEXTURE_ARB 0x84E1
81 #define GL_MAX_TEXTURES_UNITS_ARB 0x84E2
82 #define GL_TEXTURE0_ARB 0x84C0
83 #define GL_TEXTURE1_ARB 0x84C1
84 #define GL_TEXTURE2_ARB 0x84C2
85 #define GL_TEXTURE3_ARB 0x84C3
86 #define GL_TEXTURE4_ARB 0x84C4
87 #define GL_TEXTURE5_ARB 0x84C5
88 #define GL_TEXTURE6_ARB 0x84C6
89 #define GL_TEXTURE7_ARB 0x84C7
90 #define GL_TEXTURE8_ARB 0x84C8
91 #define GL_TEXTURE9_ARB 0x84C9
92 #define GL_TEXTURE10_ARB 0x84CA
93 #define GL_TEXTURE11_ARB 0x84CB
94 #define GL_TEXTURE12_ARB 0x84CC
95 #define GL_TEXTURE13_ARB 0x84CD
96 #define GL_TEXTURE14_ARB 0x84CE
97 #define GL_TEXTURE15_ARB 0x84CF
98 #define GL_TEXTURE16_ARB 0x84D0
99 #define GL_TEXTURE17_ARB 0x84D1
100 #define GL_TEXTURE18_ARB 0x84D2
101 #define GL_TEXTURE19_ARB 0x84D3
102 #define GL_TEXTURE20_ARB 0x84D4
103 #define GL_TEXTURE21_ARB 0x84D5
104 #define GL_TEXTURE22_ARB 0x84D6
105 #define GL_TEXTURE23_ARB 0x84D7
106 #define GL_TEXTURE24_ARB 0x84D8
107 #define GL_TEXTURE25_ARB 0x84D9
108 #define GL_TEXTURE26_ARB 0x84DA
109 #define GL_TEXTURE27_ARB 0x84DB
110 #define GL_TEXTURE28_ARB 0x84DC
111 #define GL_TEXTURE29_ARB 0x84DD
112 #define GL_TEXTURE30_ARB 0x84DE
113 #define GL_TEXTURE31_ARB 0x84DF
116 // GL_EXT_compiled_vertex_array
117 extern int gl_supportslockarrays;
118 extern void (GLAPIENTRY *qglLockArraysEXT) (GLint first, GLint count);
119 extern void (GLAPIENTRY *qglUnlockArraysEXT) (void);
121 // GL_ARB_texture_env_combine
122 extern int gl_combine_extension;
123 #ifndef GL_COMBINE_ARB
124 #define GL_COMBINE_ARB 0x8570
125 #define GL_COMBINE_RGB_ARB 0x8571
126 #define GL_COMBINE_ALPHA_ARB 0x8572
127 #define GL_SOURCE0_RGB_ARB 0x8580
128 #define GL_SOURCE1_RGB_ARB 0x8581
129 #define GL_SOURCE2_RGB_ARB 0x8582
130 #define GL_SOURCE0_ALPHA_ARB 0x8588
131 #define GL_SOURCE1_ALPHA_ARB 0x8589
132 #define GL_SOURCE2_ALPHA_ARB 0x858A
133 #define GL_OPERAND0_RGB_ARB 0x8590
134 #define GL_OPERAND1_RGB_ARB 0x8591
135 #define GL_OPERAND2_RGB_ARB 0x8592
136 #define GL_OPERAND0_ALPHA_ARB 0x8598
137 #define GL_OPERAND1_ALPHA_ARB 0x8599
138 #define GL_OPERAND2_ALPHA_ARB 0x859A
139 #define GL_RGB_SCALE_ARB 0x8573
140 #define GL_ADD_SIGNED_ARB 0x8574
141 #define GL_INTERPOLATE_ARB 0x8575
142 #define GL_SUBTRACT_ARB 0x84E7
143 #define GL_CONSTANT_ARB 0x8576
144 #define GL_PRIMARY_COLOR_ARB 0x8577
145 #define GL_PREVIOUS_ARB 0x8578
148 extern cvar_t gl_combine;
153 //extern void (GLAPIENTRY *glColorTableEXT)(int, int, int, int, int, const void*);