Brian Paul | 7e1161b | 1999-11-25 18:17:04 +0000 | [diff] [blame^] | 1 | /* $Id: glapi.c,v 1.9 1999/11/25 18:17:04 brianp Exp $ */ |
Brian Paul | fbd8f21 | 1999-11-11 01:22:25 +0000 | [diff] [blame] | 2 | |
| 3 | /* |
| 4 | * Mesa 3-D graphics library |
| 5 | * Version: 3.3 |
| 6 | * |
| 7 | * Copyright (C) 1999 Brian Paul All Rights Reserved. |
| 8 | * |
| 9 | * Permission is hereby granted, free of charge, to any person obtaining a |
| 10 | * copy of this software and associated documentation files (the "Software"), |
| 11 | * to deal in the Software without restriction, including without limitation |
| 12 | * the rights to use, copy, modify, merge, publish, distribute, sublicense, |
| 13 | * and/or sell copies of the Software, and to permit persons to whom the |
| 14 | * Software is furnished to do so, subject to the following conditions: |
| 15 | * |
| 16 | * The above copyright notice and this permission notice shall be included |
| 17 | * in all copies or substantial portions of the Software. |
| 18 | * |
| 19 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS |
| 20 | * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, |
| 21 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL |
| 22 | * BRIAN PAUL BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN |
| 23 | * AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN |
| 24 | * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. |
| 25 | */ |
| 26 | |
| 27 | |
Brian Paul | 7e1161b | 1999-11-25 18:17:04 +0000 | [diff] [blame^] | 28 | /* |
| 29 | * This file manages the OpenGL API dispatch layer. |
| 30 | * The dispatch table (struct _glapi_table) is basically just a list |
| 31 | * of function pointers. |
| 32 | * There are functions to set/get the current dispatch table for the |
| 33 | * current thread and to manage registration/dispatch of dynamically |
| 34 | * added extension functions. |
| 35 | */ |
| 36 | |
| 37 | |
| 38 | |
Brian Paul | fbd8f21 | 1999-11-11 01:22:25 +0000 | [diff] [blame] | 39 | #include <assert.h> |
Brian Paul | eb1f282 | 1999-11-11 15:26:45 +0000 | [diff] [blame] | 40 | #include <stdlib.h> /* to get NULL */ |
Brian Paul | 7fb54ae | 1999-11-19 22:33:50 +0000 | [diff] [blame] | 41 | #include <string.h> |
Brian Paul | fbd8f21 | 1999-11-11 01:22:25 +0000 | [diff] [blame] | 42 | #include "glapi.h" |
| 43 | #include "glapinoop.h" |
| 44 | |
| 45 | |
| 46 | |
Brian Paul | 7fb54ae | 1999-11-19 22:33:50 +0000 | [diff] [blame] | 47 | /* |
| 48 | * Define the DISPATCH_SETUP and DISPATCH macros here dependant on |
| 49 | * whether or not threading is enabled. |
| 50 | */ |
| 51 | #if defined(THREADS) |
Brian Paul | fbd8f21 | 1999-11-11 01:22:25 +0000 | [diff] [blame] | 52 | |
Brian Paul | 7fb54ae | 1999-11-19 22:33:50 +0000 | [diff] [blame] | 53 | /*** Thread-safe API dispatch ***/ |
| 54 | #include "mthreads.h" |
| 55 | static MesaTSD mesa_dispatch_tsd; |
| 56 | static void mesa_dispatch_thread_init() { |
| 57 | MesaInitTSD(&mesa_dispatch_tsd); |
| 58 | } |
| 59 | #define DISPATCH_SETUP struct _glapi_table *dispatch = (struct _glapi_table *) MesaGetTSD(&mesa_dispatch_tsd) |
Brian Paul | 7e1161b | 1999-11-25 18:17:04 +0000 | [diff] [blame^] | 60 | #define DISPATCH(FUNC, ARGS) (dispatch->FUNC) ARGS |
Brian Paul | 7fb54ae | 1999-11-19 22:33:50 +0000 | [diff] [blame] | 61 | |
Brian Paul | fbd8f21 | 1999-11-11 01:22:25 +0000 | [diff] [blame] | 62 | |
| 63 | #else |
| 64 | |
Brian Paul | 7fb54ae | 1999-11-19 22:33:50 +0000 | [diff] [blame] | 65 | /*** Non-threaded API dispatch ***/ |
Brian Paul | fbd8f21 | 1999-11-11 01:22:25 +0000 | [diff] [blame] | 66 | static struct _glapi_table *Dispatch = &__glapi_noop_table; |
Brian Paul | 7fb54ae | 1999-11-19 22:33:50 +0000 | [diff] [blame] | 67 | #define DISPATCH_SETUP |
Brian Paul | 7e1161b | 1999-11-25 18:17:04 +0000 | [diff] [blame^] | 68 | #define DISPATCH(FUNC, ARGS) (Dispatch->FUNC) ARGS |
Brian Paul | fbd8f21 | 1999-11-11 01:22:25 +0000 | [diff] [blame] | 69 | |
| 70 | #endif |
| 71 | |
| 72 | |
Brian Paul | 7fb54ae | 1999-11-19 22:33:50 +0000 | [diff] [blame] | 73 | |
| 74 | /* |
| 75 | * Set the global or per-thread dispatch table pointer. |
| 76 | */ |
| 77 | void |
| 78 | _glapi_set_dispatch(struct _glapi_table *dispatch) |
| 79 | { |
| 80 | if (!dispatch) { |
| 81 | /* use the no-op functions */ |
| 82 | dispatch = &__glapi_noop_table; |
| 83 | } |
| 84 | #ifdef DEBUG |
| 85 | else { |
| 86 | _glapi_check_table(dispatch); |
| 87 | } |
| 88 | #endif |
| 89 | |
| 90 | #if defined(THREADS) |
| 91 | MesaSetTSD(&mesa_dispatch_tsd, (void*) dispatch, mesa_dispatch_thread_init); |
| 92 | #else |
| 93 | Dispatch = dispatch; |
| 94 | #endif |
| 95 | } |
| 96 | |
| 97 | |
| 98 | /* |
| 99 | * Get the global or per-thread dispatch table pointer. |
| 100 | */ |
| 101 | struct _glapi_table * |
| 102 | _glapi_get_dispatch(void) |
| 103 | { |
| 104 | #if defined(THREADS) |
| 105 | /* return this thread's dispatch pointer */ |
| 106 | return (struct _glapi_table *) MesaGetTSD(&mesa_dispatch_tsd); |
| 107 | #else |
| 108 | return Dispatch; |
| 109 | #endif |
| 110 | } |
| 111 | |
| 112 | |
| 113 | /* |
| 114 | * Get API dispatcher version string. |
| 115 | * XXX this isn't well defined yet. |
| 116 | */ |
| 117 | const char * |
| 118 | _glapi_get_version(void) |
| 119 | { |
| 120 | return "1.2"; |
| 121 | } |
| 122 | |
| 123 | |
| 124 | /* |
| 125 | * Return list of hard-coded extension entrypoints in the dispatch table. |
| 126 | * XXX this isn't well defined yet. |
| 127 | */ |
| 128 | const char * |
| 129 | _glapi_get_extensions(void) |
| 130 | { |
| 131 | return "GL_EXT_paletted_texture GL_EXT_compiled_vertex_array GL_EXT_point_parameters GL_EXT_polygon_offset GL_EXT_blend_minmax GL_EXT_blend_color GL_ARB_multitexture GL_INGR_blend_func_separate GL_MESA_window_pos GL_MESA_resize_buffers"; |
| 132 | } |
| 133 | |
| 134 | |
| 135 | |
| 136 | /* |
| 137 | * XXX the following dynamic extension code is just a prototype and |
| 138 | * not used yet. |
| 139 | */ |
| 140 | struct _glapi_ext_entrypoint { |
| 141 | const char *Name; |
| 142 | GLuint Offset; |
| 143 | }; |
| 144 | |
| 145 | #define MAX_EXT_ENTRYPOINTS 100 |
| 146 | |
| 147 | static struct _glapi_ext_entrypoint ExtEntryTable[MAX_EXT_ENTRYPOINTS]; |
| 148 | static GLuint NumExtEntryPoints; |
| 149 | |
| 150 | |
| 151 | |
| 152 | /* |
| 153 | * Dynamically allocate an extension entry point. |
| 154 | * Return a slot number or -1 if table is full. |
| 155 | */ |
| 156 | GLint |
| 157 | _glapi_alloc_entrypoint(const char *funcName) |
| 158 | { |
| 159 | GLuint i; |
| 160 | for (i = 0; i < NumExtEntryPoints; i++) { |
| 161 | if (strcmp(ExtEntryTable[i].Name, funcName) == 0) { |
| 162 | /* found it */ |
| 163 | return (GLint) ExtEntryTable[i].Offset; |
| 164 | } |
| 165 | } |
| 166 | if (NumExtEntryPoints < MAX_EXT_ENTRYPOINTS) { |
| 167 | /* add it */ |
| 168 | ExtEntryTable[NumExtEntryPoints].Name = strdup(funcName); |
| 169 | ExtEntryTable[NumExtEntryPoints].Offset = NumExtEntryPoints; /* OK? */ |
| 170 | NumExtEntryPoints++; |
| 171 | return (GLint) (NumExtEntryPoints - 1); |
| 172 | } |
| 173 | /* no more room in the table */ |
| 174 | return -1; |
| 175 | } |
| 176 | |
| 177 | |
| 178 | |
| 179 | /* |
| 180 | * Find the dynamic entry point for the named function. |
| 181 | * Return a slot number or -1 if not found. |
| 182 | */ |
| 183 | GLint |
| 184 | _glapi_get_entrypoint(const char *funcName) |
| 185 | { |
| 186 | GLuint i; |
| 187 | for (i = 0; i < NumExtEntryPoints; i++) { |
| 188 | if (strcmp(ExtEntryTable[i].Name, funcName) == 0) { |
| 189 | /* found it */ |
| 190 | return (GLint) ExtEntryTable[i].Offset; |
| 191 | } |
| 192 | } |
| 193 | /* not in table */ |
| 194 | return -1; |
| 195 | } |
| 196 | |
| 197 | |
| 198 | |
| 199 | static GLvoid * |
| 200 | get_static_proc_address(const char *funcName) |
| 201 | { |
| 202 | struct name_address { |
| 203 | const char *Name; |
| 204 | GLvoid *Address; |
| 205 | }; |
| 206 | static struct name_address apitable[] = { |
| 207 | { "glAccum", (GLvoid *) glAccum }, |
| 208 | { "glAlphaFunc", (GLvoid *) glAlphaFunc }, |
| 209 | { "glBegin", (GLvoid *) glBegin }, |
| 210 | { "glBitmap", (GLvoid *) glBitmap }, |
| 211 | /* ... many more ... */ |
| 212 | { NULL, NULL } /* end of list marker */ |
| 213 | }; |
| 214 | GLuint i; |
| 215 | for (i = 0; apitable[i].Name; i++) { |
| 216 | if (strcmp(apitable[i].Name, funcName) == 0) { |
| 217 | return apitable[i].Address; |
| 218 | } |
| 219 | } |
| 220 | return NULL; |
| 221 | } |
| 222 | |
| 223 | |
| 224 | /* |
| 225 | * Return entrypoint for named function. |
| 226 | */ |
| 227 | const GLvoid * |
| 228 | _glapi_get_proc_address(const char *funcName) |
| 229 | { |
| 230 | /* look for dynamic extension entry point */ |
| 231 | |
| 232 | /* look for static entry point */ |
| 233 | return get_static_proc_address(funcName); |
| 234 | } |
| 235 | |
| 236 | |
| 237 | |
| 238 | /* |
| 239 | * Make sure there are no NULL pointers in the given dispatch table. |
| 240 | * Intented for debugging purposes. |
| 241 | */ |
| 242 | void |
| 243 | _glapi_check_table(const struct _glapi_table *table) |
| 244 | { |
| 245 | assert(table->Accum); |
| 246 | assert(table->AlphaFunc); |
| 247 | assert(table->Begin); |
| 248 | assert(table->Bitmap); |
| 249 | assert(table->BlendFunc); |
| 250 | assert(table->CallList); |
| 251 | assert(table->CallLists); |
| 252 | assert(table->Clear); |
| 253 | assert(table->ClearAccum); |
| 254 | assert(table->ClearColor); |
| 255 | assert(table->ClearDepth); |
| 256 | assert(table->ClearIndex); |
| 257 | assert(table->ClearStencil); |
| 258 | assert(table->ClipPlane); |
| 259 | assert(table->Color3b); |
| 260 | assert(table->Color3bv); |
| 261 | assert(table->Color3d); |
| 262 | assert(table->Color3dv); |
| 263 | assert(table->Color3f); |
| 264 | assert(table->Color3fv); |
| 265 | assert(table->Color3i); |
| 266 | assert(table->Color3iv); |
| 267 | assert(table->Color3s); |
| 268 | assert(table->Color3sv); |
| 269 | assert(table->Color3ub); |
| 270 | assert(table->Color3ubv); |
| 271 | assert(table->Color3ui); |
| 272 | assert(table->Color3uiv); |
| 273 | assert(table->Color3us); |
| 274 | assert(table->Color3usv); |
| 275 | assert(table->Color4b); |
| 276 | assert(table->Color4bv); |
| 277 | assert(table->Color4d); |
| 278 | assert(table->Color4dv); |
| 279 | assert(table->Color4f); |
| 280 | assert(table->Color4fv); |
| 281 | assert(table->Color4i); |
| 282 | assert(table->Color4iv); |
| 283 | assert(table->Color4s); |
| 284 | assert(table->Color4sv); |
| 285 | assert(table->Color4ub); |
| 286 | assert(table->Color4ubv); |
| 287 | assert(table->Color4ui); |
| 288 | assert(table->Color4uiv); |
| 289 | assert(table->Color4us); |
| 290 | assert(table->Color4usv); |
| 291 | assert(table->ColorMask); |
| 292 | assert(table->ColorMaterial); |
| 293 | assert(table->CopyPixels); |
| 294 | assert(table->CullFace); |
| 295 | assert(table->DeleteLists); |
| 296 | assert(table->DepthFunc); |
| 297 | assert(table->DepthMask); |
| 298 | assert(table->DepthRange); |
| 299 | assert(table->Disable); |
| 300 | assert(table->DrawBuffer); |
| 301 | assert(table->DrawElements); |
| 302 | assert(table->DrawPixels); |
| 303 | assert(table->EdgeFlag); |
| 304 | assert(table->EdgeFlagv); |
| 305 | assert(table->Enable); |
| 306 | assert(table->End); |
| 307 | assert(table->EndList); |
| 308 | assert(table->EvalCoord1d); |
| 309 | assert(table->EvalCoord1dv); |
| 310 | assert(table->EvalCoord1f); |
| 311 | assert(table->EvalCoord1fv); |
| 312 | assert(table->EvalCoord2d); |
| 313 | assert(table->EvalCoord2dv); |
| 314 | assert(table->EvalCoord2f); |
| 315 | assert(table->EvalCoord2fv); |
| 316 | assert(table->EvalMesh1); |
| 317 | assert(table->EvalMesh2); |
| 318 | assert(table->EvalPoint1); |
| 319 | assert(table->EvalPoint2); |
| 320 | assert(table->FeedbackBuffer); |
| 321 | assert(table->Finish); |
| 322 | assert(table->Flush); |
| 323 | assert(table->Fogf); |
| 324 | assert(table->Fogfv); |
| 325 | assert(table->Fogi); |
| 326 | assert(table->Fogiv); |
| 327 | assert(table->FrontFace); |
| 328 | assert(table->Frustum); |
| 329 | assert(table->GenLists); |
| 330 | assert(table->GetBooleanv); |
| 331 | assert(table->GetClipPlane); |
| 332 | assert(table->GetDoublev); |
| 333 | assert(table->GetError); |
| 334 | assert(table->GetFloatv); |
| 335 | assert(table->GetIntegerv); |
| 336 | assert(table->GetLightfv); |
| 337 | assert(table->GetLightiv); |
| 338 | assert(table->GetMapdv); |
| 339 | assert(table->GetMapfv); |
| 340 | assert(table->GetMapiv); |
| 341 | assert(table->GetMaterialfv); |
| 342 | assert(table->GetMaterialiv); |
| 343 | assert(table->GetPixelMapfv); |
| 344 | assert(table->GetPixelMapuiv); |
| 345 | assert(table->GetPixelMapusv); |
| 346 | assert(table->GetPolygonStipple); |
| 347 | assert(table->GetString); |
| 348 | assert(table->GetTexEnvfv); |
| 349 | assert(table->GetTexEnviv); |
| 350 | assert(table->GetTexGendv); |
| 351 | assert(table->GetTexGenfv); |
| 352 | assert(table->GetTexGeniv); |
| 353 | assert(table->GetTexImage); |
| 354 | assert(table->GetTexLevelParameterfv); |
| 355 | assert(table->GetTexLevelParameteriv); |
| 356 | assert(table->GetTexParameterfv); |
| 357 | assert(table->GetTexParameteriv); |
| 358 | assert(table->Hint); |
| 359 | assert(table->IndexMask); |
| 360 | assert(table->Indexd); |
| 361 | assert(table->Indexdv); |
| 362 | assert(table->Indexf); |
| 363 | assert(table->Indexfv); |
| 364 | assert(table->Indexi); |
| 365 | assert(table->Indexiv); |
| 366 | assert(table->Indexs); |
| 367 | assert(table->Indexsv); |
| 368 | assert(table->InitNames); |
| 369 | assert(table->IsEnabled); |
| 370 | assert(table->IsList); |
| 371 | assert(table->LightModelf); |
| 372 | assert(table->LightModelfv); |
| 373 | assert(table->LightModeli); |
| 374 | assert(table->LightModeliv); |
| 375 | assert(table->Lightf); |
| 376 | assert(table->Lightfv); |
| 377 | assert(table->Lighti); |
| 378 | assert(table->Lightiv); |
| 379 | assert(table->LineStipple); |
| 380 | assert(table->LineWidth); |
| 381 | assert(table->ListBase); |
| 382 | assert(table->LoadIdentity); |
| 383 | assert(table->LoadMatrixd); |
| 384 | assert(table->LoadMatrixf); |
| 385 | assert(table->LoadName); |
| 386 | assert(table->LogicOp); |
| 387 | assert(table->Map1d); |
| 388 | assert(table->Map1f); |
| 389 | assert(table->Map2d); |
| 390 | assert(table->Map2f); |
| 391 | assert(table->MapGrid1d); |
| 392 | assert(table->MapGrid1f); |
| 393 | assert(table->MapGrid2d); |
| 394 | assert(table->MapGrid2f); |
| 395 | assert(table->Materialf); |
| 396 | assert(table->Materialfv); |
| 397 | assert(table->Materiali); |
| 398 | assert(table->Materialiv); |
| 399 | assert(table->MatrixMode); |
| 400 | assert(table->MultMatrixd); |
| 401 | assert(table->MultMatrixf); |
| 402 | assert(table->NewList); |
| 403 | assert(table->Normal3b); |
| 404 | assert(table->Normal3bv); |
| 405 | assert(table->Normal3d); |
| 406 | assert(table->Normal3dv); |
| 407 | assert(table->Normal3f); |
| 408 | assert(table->Normal3fv); |
| 409 | assert(table->Normal3i); |
| 410 | assert(table->Normal3iv); |
| 411 | assert(table->Normal3s); |
| 412 | assert(table->Normal3sv); |
| 413 | assert(table->Ortho); |
| 414 | assert(table->PassThrough); |
| 415 | assert(table->PixelMapfv); |
| 416 | assert(table->PixelMapuiv); |
| 417 | assert(table->PixelMapusv); |
| 418 | assert(table->PixelStoref); |
| 419 | assert(table->PixelStorei); |
| 420 | assert(table->PixelTransferf); |
| 421 | assert(table->PixelTransferi); |
| 422 | assert(table->PixelZoom); |
| 423 | assert(table->PointSize); |
| 424 | assert(table->PolygonMode); |
| 425 | assert(table->PolygonOffset); |
| 426 | assert(table->PolygonStipple); |
| 427 | assert(table->PopAttrib); |
| 428 | assert(table->PopMatrix); |
| 429 | assert(table->PopName); |
| 430 | assert(table->PushAttrib); |
| 431 | assert(table->PushMatrix); |
| 432 | assert(table->PushName); |
| 433 | assert(table->RasterPos2d); |
| 434 | assert(table->RasterPos2dv); |
| 435 | assert(table->RasterPos2f); |
| 436 | assert(table->RasterPos2fv); |
| 437 | assert(table->RasterPos2i); |
| 438 | assert(table->RasterPos2iv); |
| 439 | assert(table->RasterPos2s); |
| 440 | assert(table->RasterPos2sv); |
| 441 | assert(table->RasterPos3d); |
| 442 | assert(table->RasterPos3dv); |
| 443 | assert(table->RasterPos3f); |
| 444 | assert(table->RasterPos3fv); |
| 445 | assert(table->RasterPos3i); |
| 446 | assert(table->RasterPos3iv); |
| 447 | assert(table->RasterPos3s); |
| 448 | assert(table->RasterPos3sv); |
| 449 | assert(table->RasterPos4d); |
| 450 | assert(table->RasterPos4dv); |
| 451 | assert(table->RasterPos4f); |
| 452 | assert(table->RasterPos4fv); |
| 453 | assert(table->RasterPos4i); |
| 454 | assert(table->RasterPos4iv); |
| 455 | assert(table->RasterPos4s); |
| 456 | assert(table->RasterPos4sv); |
| 457 | assert(table->ReadBuffer); |
| 458 | assert(table->ReadPixels); |
| 459 | assert(table->Rectd); |
| 460 | assert(table->Rectdv); |
| 461 | assert(table->Rectf); |
| 462 | assert(table->Rectfv); |
| 463 | assert(table->Recti); |
| 464 | assert(table->Rectiv); |
| 465 | assert(table->Rects); |
| 466 | assert(table->Rectsv); |
| 467 | assert(table->RenderMode); |
| 468 | assert(table->Rotated); |
| 469 | assert(table->Rotatef); |
| 470 | assert(table->Scaled); |
| 471 | assert(table->Scalef); |
| 472 | assert(table->Scissor); |
| 473 | assert(table->SelectBuffer); |
| 474 | assert(table->ShadeModel); |
| 475 | assert(table->StencilFunc); |
| 476 | assert(table->StencilMask); |
| 477 | assert(table->StencilOp); |
| 478 | assert(table->TexCoord1d); |
| 479 | assert(table->TexCoord1dv); |
| 480 | assert(table->TexCoord1f); |
| 481 | assert(table->TexCoord1fv); |
| 482 | assert(table->TexCoord1i); |
| 483 | assert(table->TexCoord1iv); |
| 484 | assert(table->TexCoord1s); |
| 485 | assert(table->TexCoord1sv); |
| 486 | assert(table->TexCoord2d); |
| 487 | assert(table->TexCoord2dv); |
| 488 | assert(table->TexCoord2f); |
| 489 | assert(table->TexCoord2fv); |
| 490 | assert(table->TexCoord2i); |
| 491 | assert(table->TexCoord2iv); |
| 492 | assert(table->TexCoord2s); |
| 493 | assert(table->TexCoord2sv); |
| 494 | assert(table->TexCoord3d); |
| 495 | assert(table->TexCoord3dv); |
| 496 | assert(table->TexCoord3f); |
| 497 | assert(table->TexCoord3fv); |
| 498 | assert(table->TexCoord3i); |
| 499 | assert(table->TexCoord3iv); |
| 500 | assert(table->TexCoord3s); |
| 501 | assert(table->TexCoord3sv); |
| 502 | assert(table->TexCoord4d); |
| 503 | assert(table->TexCoord4dv); |
| 504 | assert(table->TexCoord4f); |
| 505 | assert(table->TexCoord4fv); |
| 506 | assert(table->TexCoord4i); |
| 507 | assert(table->TexCoord4iv); |
| 508 | assert(table->TexCoord4s); |
| 509 | assert(table->TexCoord4sv); |
| 510 | assert(table->TexEnvf); |
| 511 | assert(table->TexEnvfv); |
| 512 | assert(table->TexEnvi); |
| 513 | assert(table->TexEnviv); |
| 514 | assert(table->TexGend); |
| 515 | assert(table->TexGendv); |
| 516 | assert(table->TexGenf); |
| 517 | assert(table->TexGenfv); |
| 518 | assert(table->TexGeni); |
| 519 | assert(table->TexGeniv); |
| 520 | assert(table->TexImage1D); |
| 521 | assert(table->TexImage2D); |
| 522 | assert(table->TexParameterf); |
| 523 | assert(table->TexParameterfv); |
| 524 | assert(table->TexParameteri); |
| 525 | assert(table->TexParameteriv); |
| 526 | assert(table->Translated); |
| 527 | assert(table->Translatef); |
| 528 | assert(table->Vertex2d); |
| 529 | assert(table->Vertex2dv); |
| 530 | assert(table->Vertex2f); |
| 531 | assert(table->Vertex2fv); |
| 532 | assert(table->Vertex2i); |
| 533 | assert(table->Vertex2iv); |
| 534 | assert(table->Vertex2s); |
| 535 | assert(table->Vertex2sv); |
| 536 | assert(table->Vertex3d); |
| 537 | assert(table->Vertex3dv); |
| 538 | assert(table->Vertex3f); |
| 539 | assert(table->Vertex3fv); |
| 540 | assert(table->Vertex3i); |
| 541 | assert(table->Vertex3iv); |
| 542 | assert(table->Vertex3s); |
| 543 | assert(table->Vertex3sv); |
| 544 | assert(table->Vertex4d); |
| 545 | assert(table->Vertex4dv); |
| 546 | assert(table->Vertex4f); |
| 547 | assert(table->Vertex4fv); |
| 548 | assert(table->Vertex4i); |
| 549 | assert(table->Vertex4iv); |
| 550 | assert(table->Vertex4s); |
| 551 | assert(table->Vertex4sv); |
| 552 | assert(table->Viewport); |
| 553 | |
| 554 | #ifdef _GLAPI_VERSION_1_1 |
| 555 | assert(table->AreTexturesResident); |
| 556 | assert(table->ArrayElement); |
| 557 | assert(table->BindTexture); |
| 558 | assert(table->ColorPointer); |
| 559 | assert(table->CopyTexImage1D); |
| 560 | assert(table->CopyTexImage2D); |
| 561 | assert(table->CopyTexSubImage1D); |
| 562 | assert(table->CopyTexSubImage2D); |
| 563 | assert(table->DeleteTextures); |
| 564 | assert(table->DisableClientState); |
| 565 | assert(table->DrawArrays); |
| 566 | assert(table->EdgeFlagPointer); |
| 567 | assert(table->EnableClientState); |
| 568 | assert(table->GenTextures); |
| 569 | assert(table->GetPointerv); |
| 570 | assert(table->IndexPointer); |
| 571 | assert(table->Indexub); |
| 572 | assert(table->Indexubv); |
| 573 | assert(table->InterleavedArrays); |
| 574 | assert(table->IsTexture); |
| 575 | assert(table->NormalPointer); |
| 576 | assert(table->PopClientAttrib); |
| 577 | assert(table->PrioritizeTextures); |
| 578 | assert(table->PushClientAttrib); |
| 579 | assert(table->TexCoordPointer); |
| 580 | assert(table->TexSubImage1D); |
| 581 | assert(table->TexSubImage2D); |
| 582 | assert(table->VertexPointer); |
| 583 | #endif |
| 584 | |
| 585 | #ifdef _GLAPI_VERSION_1_2 |
| 586 | assert(table->CopyTexSubImage3D); |
| 587 | assert(table->DrawRangeElements); |
| 588 | assert(table->TexImage3D); |
| 589 | assert(table->TexSubImage3D); |
| 590 | #ifdef _GLAPI_ARB_imaging |
| 591 | assert(table->BlendColor); |
| 592 | assert(table->BlendEquation); |
| 593 | assert(table->ColorSubTable); |
| 594 | assert(table->ColorTable); |
| 595 | assert(table->ColorTableParameterfv); |
| 596 | assert(table->ColorTableParameteriv); |
| 597 | assert(table->ConvolutionFilter1D); |
| 598 | assert(table->ConvolutionFilter2D); |
| 599 | assert(table->ConvolutionParameterf); |
| 600 | assert(table->ConvolutionParameterfv); |
| 601 | assert(table->ConvolutionParameteri); |
| 602 | assert(table->ConvolutionParameteriv); |
| 603 | assert(table->CopyColorSubTable); |
| 604 | assert(table->CopyColorTable); |
| 605 | assert(table->CopyConvolutionFilter1D); |
| 606 | assert(table->CopyConvolutionFilter2D); |
| 607 | assert(table->GetColorTable); |
| 608 | assert(table->GetColorTableParameterfv); |
| 609 | assert(table->GetColorTableParameteriv); |
| 610 | assert(table->GetConvolutionFilter); |
| 611 | assert(table->GetConvolutionParameterfv); |
| 612 | assert(table->GetConvolutionParameteriv); |
| 613 | assert(table->GetHistogram); |
| 614 | assert(table->GetHistogramParameterfv); |
| 615 | assert(table->GetHistogramParameteriv); |
| 616 | assert(table->GetMinmax); |
| 617 | assert(table->GetMinmaxParameterfv); |
| 618 | assert(table->GetMinmaxParameteriv); |
| 619 | assert(table->Histogram); |
| 620 | assert(table->Minmax); |
| 621 | assert(table->ResetHistogram); |
| 622 | assert(table->ResetMinmax); |
| 623 | assert(table->SeparableFilter2D); |
| 624 | #endif |
| 625 | #endif |
| 626 | |
| 627 | |
| 628 | #ifdef _GLAPI_EXT_paletted_texture |
| 629 | assert(table->ColorTableEXT); |
| 630 | assert(table->ColorSubTableEXT); |
| 631 | assert(table->GetColorTableEXT); |
| 632 | assert(table->GetColorTableParameterfvEXT); |
| 633 | assert(table->GetColorTableParameterivEXT); |
| 634 | #endif |
| 635 | |
| 636 | #ifdef _GLAPI_EXT_compiled_vertex_array |
| 637 | assert(table->LockArraysEXT); |
| 638 | assert(table->UnlockArraysEXT); |
| 639 | #endif |
| 640 | |
| 641 | #ifdef _GLAPI_EXT_point_parameter |
| 642 | assert(table->PointParameterfEXT); |
| 643 | assert(table->PointParameterfvEXT); |
| 644 | #endif |
| 645 | |
| 646 | #ifdef _GLAPI_EXT_polygon_offset |
| 647 | assert(table->PolygonOffsetEXT); |
| 648 | #endif |
| 649 | |
| 650 | #ifdef _GLAPI_ARB_multitexture |
| 651 | assert(table->ActiveTextureARB); |
| 652 | assert(table->ClientActiveTextureARB); |
| 653 | assert(table->MultiTexCoord1dARB); |
| 654 | assert(table->MultiTexCoord1dvARB); |
| 655 | assert(table->MultiTexCoord1fARB); |
| 656 | assert(table->MultiTexCoord1fvARB); |
| 657 | assert(table->MultiTexCoord1iARB); |
| 658 | assert(table->MultiTexCoord1ivARB); |
| 659 | assert(table->MultiTexCoord1sARB); |
| 660 | assert(table->MultiTexCoord1svARB); |
| 661 | assert(table->MultiTexCoord2dARB); |
| 662 | assert(table->MultiTexCoord2dvARB); |
| 663 | assert(table->MultiTexCoord2fARB); |
| 664 | assert(table->MultiTexCoord2fvARB); |
| 665 | assert(table->MultiTexCoord2iARB); |
| 666 | assert(table->MultiTexCoord2ivARB); |
| 667 | assert(table->MultiTexCoord2sARB); |
| 668 | assert(table->MultiTexCoord2svARB); |
| 669 | assert(table->MultiTexCoord3dARB); |
| 670 | assert(table->MultiTexCoord3dvARB); |
| 671 | assert(table->MultiTexCoord3fARB); |
| 672 | assert(table->MultiTexCoord3fvARB); |
| 673 | assert(table->MultiTexCoord3iARB); |
| 674 | assert(table->MultiTexCoord3ivARB); |
| 675 | assert(table->MultiTexCoord3sARB); |
| 676 | assert(table->MultiTexCoord3svARB); |
| 677 | assert(table->MultiTexCoord4dARB); |
| 678 | assert(table->MultiTexCoord4dvARB); |
| 679 | assert(table->MultiTexCoord4fARB); |
| 680 | assert(table->MultiTexCoord4fvARB); |
| 681 | assert(table->MultiTexCoord4iARB); |
| 682 | assert(table->MultiTexCoord4ivARB); |
| 683 | assert(table->MultiTexCoord4sARB); |
| 684 | assert(table->MultiTexCoord4svARB); |
| 685 | #endif |
| 686 | |
| 687 | #ifdef _GLAPI_INGR_blend_func_separate |
| 688 | assert(table->BlendFuncSeparateINGR); |
| 689 | #endif |
| 690 | |
| 691 | #ifdef _GLAPI_MESA_window_pos |
| 692 | assert(table->WindowPos4fMESA); |
| 693 | #endif |
| 694 | |
| 695 | #ifdef _GLAPI_MESA_resize_buffers |
| 696 | assert(table->ResizeBuffersMESA); |
| 697 | #endif |
| 698 | } |
| 699 | |
| 700 | |
| 701 | |
Brian Paul | 7e1161b | 1999-11-25 18:17:04 +0000 | [diff] [blame^] | 702 | /* |
| 703 | * Generate the GL entrypoint functions here. |
| 704 | */ |
Brian Paul | fbd8f21 | 1999-11-11 01:22:25 +0000 | [diff] [blame] | 705 | |
Brian Paul | 7e1161b | 1999-11-25 18:17:04 +0000 | [diff] [blame^] | 706 | #define KEYWORD1 |
| 707 | #define KEYWORD2 GLAPIENTRY |
| 708 | #ifdef USE_MGL_NAMESPACE |
| 709 | #define NAME(func) mgl##func |
| 710 | #else |
| 711 | #define NAME(func) gl##func |
Brian Paul | fbd8f21 | 1999-11-11 01:22:25 +0000 | [diff] [blame] | 712 | #endif |
| 713 | |
Brian Paul | 7e1161b | 1999-11-25 18:17:04 +0000 | [diff] [blame^] | 714 | #include "glapitemp.h" |
Brian Paul | fbd8f21 | 1999-11-11 01:22:25 +0000 | [diff] [blame] | 715 | |
Brian Paul | 7fb54ae | 1999-11-19 22:33:50 +0000 | [diff] [blame] | 716 | |
| 717 | |
Brian Paul | fbd8f21 | 1999-11-11 01:22:25 +0000 | [diff] [blame] | 718 | #ifdef DEBUG |
| 719 | /* |
| 720 | * This struct is just used to be sure we've defined all the API functions. |
| 721 | */ |
| 722 | static struct _glapi_table completeness_test = { |
| 723 | glAccum, |
| 724 | glAlphaFunc, |
| 725 | glBegin, |
| 726 | glBitmap, |
| 727 | glBlendFunc, |
| 728 | glCallList, |
| 729 | glCallLists, |
| 730 | glClear, |
| 731 | glClearAccum, |
| 732 | glClearColor, |
| 733 | glClearDepth, |
| 734 | glClearIndex, |
| 735 | glClearStencil, |
| 736 | glClipPlane, |
| 737 | glColor3b, |
| 738 | glColor3bv, |
| 739 | glColor3d, |
| 740 | glColor3dv, |
| 741 | glColor3f, |
| 742 | glColor3fv, |
| 743 | glColor3i, |
| 744 | glColor3iv, |
| 745 | glColor3s, |
| 746 | glColor3sv, |
| 747 | glColor3ub, |
| 748 | glColor3ubv, |
| 749 | glColor3ui, |
| 750 | glColor3uiv, |
| 751 | glColor3us, |
| 752 | glColor3usv, |
| 753 | glColor4b, |
| 754 | glColor4bv, |
| 755 | glColor4d, |
| 756 | glColor4dv, |
| 757 | glColor4f, |
| 758 | glColor4fv, |
| 759 | glColor4i, |
| 760 | glColor4iv, |
| 761 | glColor4s, |
| 762 | glColor4sv, |
| 763 | glColor4ub, |
| 764 | glColor4ubv, |
| 765 | glColor4ui, |
| 766 | glColor4uiv, |
| 767 | glColor4us, |
| 768 | glColor4usv, |
| 769 | glColorMask, |
| 770 | glColorMaterial, |
| 771 | glCopyPixels, |
| 772 | glCullFace, |
| 773 | glDeleteLists, |
| 774 | glDepthFunc, |
| 775 | glDepthMask, |
| 776 | glDepthRange, |
| 777 | glDisable, |
| 778 | glDrawBuffer, |
| 779 | glDrawPixels, |
| 780 | glEdgeFlag, |
| 781 | glEdgeFlagv, |
| 782 | glEnable, |
| 783 | glEnd, |
| 784 | glEndList, |
| 785 | glEvalCoord1d, |
| 786 | glEvalCoord1dv, |
| 787 | glEvalCoord1f, |
| 788 | glEvalCoord1fv, |
| 789 | glEvalCoord2d, |
| 790 | glEvalCoord2dv, |
| 791 | glEvalCoord2f, |
| 792 | glEvalCoord2fv, |
| 793 | glEvalMesh1, |
| 794 | glEvalMesh2, |
| 795 | glEvalPoint1, |
| 796 | glEvalPoint2, |
| 797 | glFeedbackBuffer, |
| 798 | glFinish, |
| 799 | glFlush, |
| 800 | glFogf, |
| 801 | glFogfv, |
| 802 | glFogi, |
| 803 | glFogiv, |
| 804 | glFrontFace, |
| 805 | glFrustum, |
| 806 | glGenLists, |
| 807 | glGetBooleanv, |
| 808 | glGetClipPlane, |
| 809 | glGetDoublev, |
| 810 | glGetError, |
| 811 | glGetFloatv, |
| 812 | glGetIntegerv, |
| 813 | glGetLightfv, |
| 814 | glGetLightiv, |
| 815 | glGetMapdv, |
| 816 | glGetMapfv, |
| 817 | glGetMapiv, |
| 818 | glGetMaterialfv, |
| 819 | glGetMaterialiv, |
| 820 | glGetPixelMapfv, |
| 821 | glGetPixelMapuiv, |
| 822 | glGetPixelMapusv, |
| 823 | glGetPolygonStipple, |
| 824 | glGetString, |
| 825 | glGetTexEnvfv, |
| 826 | glGetTexEnviv, |
| 827 | glGetTexGendv, |
| 828 | glGetTexGenfv, |
| 829 | glGetTexGeniv, |
| 830 | glGetTexImage, |
| 831 | glGetTexLevelParameterfv, |
| 832 | glGetTexLevelParameteriv, |
| 833 | glGetTexParameterfv, |
| 834 | glGetTexParameteriv, |
| 835 | glHint, |
| 836 | glIndexMask, |
| 837 | glIndexd, |
| 838 | glIndexdv, |
| 839 | glIndexf, |
| 840 | glIndexfv, |
| 841 | glIndexi, |
| 842 | glIndexiv, |
| 843 | glIndexs, |
| 844 | glIndexsv, |
| 845 | glInitNames, |
| 846 | glIsEnabled, |
| 847 | glIsList, |
| 848 | glLightModelf, |
| 849 | glLightModelfv, |
| 850 | glLightModeli, |
| 851 | glLightModeliv, |
| 852 | glLightf, |
| 853 | glLightfv, |
| 854 | glLighti, |
| 855 | glLightiv, |
| 856 | glLineStipple, |
| 857 | glLineWidth, |
| 858 | glListBase, |
| 859 | glLoadIdentity, |
| 860 | glLoadMatrixd, |
| 861 | glLoadMatrixf, |
| 862 | glLoadName, |
| 863 | glLogicOp, |
| 864 | glMap1d, |
| 865 | glMap1f, |
| 866 | glMap2d, |
| 867 | glMap2f, |
| 868 | glMapGrid1d, |
| 869 | glMapGrid1f, |
| 870 | glMapGrid2d, |
| 871 | glMapGrid2f, |
| 872 | glMaterialf, |
| 873 | glMaterialfv, |
| 874 | glMateriali, |
| 875 | glMaterialiv, |
| 876 | glMatrixMode, |
| 877 | glMultMatrixd, |
| 878 | glMultMatrixf, |
| 879 | glNewList, |
| 880 | glNormal3b, |
| 881 | glNormal3bv, |
| 882 | glNormal3d, |
| 883 | glNormal3dv, |
| 884 | glNormal3f, |
| 885 | glNormal3fv, |
| 886 | glNormal3i, |
| 887 | glNormal3iv, |
| 888 | glNormal3s, |
| 889 | glNormal3sv, |
| 890 | glOrtho, |
| 891 | glPassThrough, |
| 892 | glPixelMapfv, |
| 893 | glPixelMapuiv, |
| 894 | glPixelMapusv, |
| 895 | glPixelStoref, |
| 896 | glPixelStorei, |
| 897 | glPixelTransferf, |
| 898 | glPixelTransferi, |
| 899 | glPixelZoom, |
| 900 | glPointSize, |
| 901 | glPolygonMode, |
| 902 | glPolygonOffset, |
| 903 | glPolygonStipple, |
| 904 | glPopAttrib, |
| 905 | glPopMatrix, |
| 906 | glPopName, |
| 907 | glPushAttrib, |
| 908 | glPushMatrix, |
| 909 | glPushName, |
| 910 | glRasterPos2d, |
| 911 | glRasterPos2dv, |
| 912 | glRasterPos2f, |
| 913 | glRasterPos2fv, |
| 914 | glRasterPos2i, |
| 915 | glRasterPos2iv, |
| 916 | glRasterPos2s, |
| 917 | glRasterPos2sv, |
| 918 | glRasterPos3d, |
| 919 | glRasterPos3dv, |
| 920 | glRasterPos3f, |
| 921 | glRasterPos3fv, |
| 922 | glRasterPos3i, |
| 923 | glRasterPos3iv, |
| 924 | glRasterPos3s, |
| 925 | glRasterPos3sv, |
| 926 | glRasterPos4d, |
| 927 | glRasterPos4dv, |
| 928 | glRasterPos4f, |
| 929 | glRasterPos4fv, |
| 930 | glRasterPos4i, |
| 931 | glRasterPos4iv, |
| 932 | glRasterPos4s, |
| 933 | glRasterPos4sv, |
| 934 | glReadBuffer, |
| 935 | glReadPixels, |
| 936 | glRectd, |
| 937 | glRectdv, |
| 938 | glRectf, |
| 939 | glRectfv, |
| 940 | glRecti, |
| 941 | glRectiv, |
| 942 | glRects, |
| 943 | glRectsv, |
| 944 | glRenderMode, |
| 945 | glRotated, |
| 946 | glRotatef, |
| 947 | glScaled, |
| 948 | glScalef, |
| 949 | glScissor, |
| 950 | glSelectBuffer, |
| 951 | glShadeModel, |
| 952 | glStencilFunc, |
| 953 | glStencilMask, |
| 954 | glStencilOp, |
| 955 | glTexCoord1d, |
| 956 | glTexCoord1dv, |
| 957 | glTexCoord1f, |
| 958 | glTexCoord1fv, |
| 959 | glTexCoord1i, |
| 960 | glTexCoord1iv, |
| 961 | glTexCoord1s, |
| 962 | glTexCoord1sv, |
| 963 | glTexCoord2d, |
| 964 | glTexCoord2dv, |
| 965 | glTexCoord2f, |
| 966 | glTexCoord2fv, |
| 967 | glTexCoord2i, |
| 968 | glTexCoord2iv, |
| 969 | glTexCoord2s, |
| 970 | glTexCoord2sv, |
| 971 | glTexCoord3d, |
| 972 | glTexCoord3dv, |
| 973 | glTexCoord3f, |
| 974 | glTexCoord3fv, |
| 975 | glTexCoord3i, |
| 976 | glTexCoord3iv, |
| 977 | glTexCoord3s, |
| 978 | glTexCoord3sv, |
| 979 | glTexCoord4d, |
| 980 | glTexCoord4dv, |
| 981 | glTexCoord4f, |
| 982 | glTexCoord4fv, |
| 983 | glTexCoord4i, |
| 984 | glTexCoord4iv, |
| 985 | glTexCoord4s, |
| 986 | glTexCoord4sv, |
| 987 | glTexEnvf, |
| 988 | glTexEnvfv, |
| 989 | glTexEnvi, |
| 990 | glTexEnviv, |
| 991 | glTexGend, |
| 992 | glTexGendv, |
| 993 | glTexGenf, |
| 994 | glTexGenfv, |
| 995 | glTexGeni, |
| 996 | glTexGeniv, |
| 997 | glTexImage1D, |
| 998 | glTexImage2D, |
| 999 | glTexParameterf, |
| 1000 | glTexParameterfv, |
| 1001 | glTexParameteri, |
| 1002 | glTexParameteriv, |
| 1003 | glTranslated, |
| 1004 | glTranslatef, |
| 1005 | glVertex2d, |
| 1006 | glVertex2dv, |
| 1007 | glVertex2f, |
| 1008 | glVertex2fv, |
| 1009 | glVertex2i, |
| 1010 | glVertex2iv, |
| 1011 | glVertex2s, |
| 1012 | glVertex2sv, |
| 1013 | glVertex3d, |
| 1014 | glVertex3dv, |
| 1015 | glVertex3f, |
| 1016 | glVertex3fv, |
| 1017 | glVertex3i, |
| 1018 | glVertex3iv, |
| 1019 | glVertex3s, |
| 1020 | glVertex3sv, |
| 1021 | glVertex4d, |
| 1022 | glVertex4dv, |
| 1023 | glVertex4f, |
| 1024 | glVertex4fv, |
| 1025 | glVertex4i, |
| 1026 | glVertex4iv, |
| 1027 | glVertex4s, |
| 1028 | glVertex4sv, |
| 1029 | glViewport, |
| 1030 | |
| 1031 | #ifdef _GLAPI_VERSION_1_1 |
| 1032 | glAreTexturesResident, |
| 1033 | glArrayElement, |
| 1034 | glBindTexture, |
| 1035 | glColorPointer, |
| 1036 | glCopyTexImage1D, |
| 1037 | glCopyTexImage2D, |
| 1038 | glCopyTexSubImage1D, |
| 1039 | glCopyTexSubImage2D, |
| 1040 | glDeleteTextures, |
| 1041 | glDisableClientState, |
| 1042 | glDrawArrays, |
| 1043 | glDrawElements, |
| 1044 | glEdgeFlagPointer, |
| 1045 | glEnableClientState, |
| 1046 | glGenTextures, |
| 1047 | glGetPointerv, |
| 1048 | glIndexPointer, |
| 1049 | glIndexub, |
| 1050 | glIndexubv, |
| 1051 | glInterleavedArrays, |
| 1052 | glIsTexture, |
| 1053 | glNormalPointer, |
| 1054 | glPopClientAttrib, |
| 1055 | glPrioritizeTextures, |
| 1056 | glPushClientAttrib, |
| 1057 | glTexCoordPointer, |
| 1058 | glTexSubImage1D, |
| 1059 | glTexSubImage2D, |
| 1060 | glVertexPointer, |
| 1061 | #endif |
| 1062 | |
| 1063 | #ifdef _GLAPI_VERSION_1_2 |
| 1064 | glCopyTexSubImage3D, |
| 1065 | glDrawRangeElements, |
| 1066 | glTexImage3D, |
| 1067 | glTexSubImage3D, |
| 1068 | |
| 1069 | #ifdef _GLAPI_ARB_imaging |
| 1070 | glBlendColor, |
| 1071 | glBlendEquation, |
| 1072 | glColorSubTable, |
| 1073 | glColorTable, |
| 1074 | glColorTableParameterfv, |
| 1075 | glColorTableParameteriv, |
| 1076 | glConvolutionFilter1D, |
| 1077 | glConvolutionFilter2D, |
| 1078 | glConvolutionParameterf, |
| 1079 | glConvolutionParameterfv, |
| 1080 | glConvolutionParameteri, |
| 1081 | glConvolutionParameteriv, |
| 1082 | glCopyColorSubTable, |
| 1083 | glCopyColorTable, |
| 1084 | glCopyConvolutionFilter1D, |
| 1085 | glCopyConvolutionFilter2D, |
| 1086 | glGetColorTable, |
| 1087 | glGetColorTableParameterfv, |
| 1088 | glGetColorTableParameteriv, |
| 1089 | glGetConvolutionFilter, |
| 1090 | glGetConvolutionParameterfv, |
| 1091 | glGetConvolutionParameteriv, |
| 1092 | glGetHistogram, |
| 1093 | glGetHistogramParameterfv, |
| 1094 | glGetHistogramParameteriv, |
| 1095 | glGetMinmax, |
| 1096 | glGetMinmaxParameterfv, |
| 1097 | glGetMinmaxParameteriv, |
| 1098 | glGetSeparableFilter, |
| 1099 | glHistogram, |
| 1100 | glMinmax, |
| 1101 | glResetHistogram, |
| 1102 | glResetMinmax, |
| 1103 | glSeparableFilter2D, |
| 1104 | #endif |
| 1105 | #endif |
| 1106 | |
| 1107 | |
| 1108 | /* |
| 1109 | * Extensions |
| 1110 | */ |
| 1111 | |
Brian Paul | 4586d87 | 1999-11-12 18:57:50 +0000 | [diff] [blame] | 1112 | #ifdef _GLAPI_EXT_paletted_texture |
Brian Paul | fbd8f21 | 1999-11-11 01:22:25 +0000 | [diff] [blame] | 1113 | glColorTableEXT, |
| 1114 | glColorSubTableEXT, |
| 1115 | glGetColorTableEXT, |
| 1116 | glGetColorTableParameterfvEXT, |
| 1117 | glGetColorTableParameterivEXT, |
| 1118 | #endif |
| 1119 | |
| 1120 | #ifdef _GLAPI_EXT_compiled_vertex_array |
| 1121 | glLockArraysEXT, |
| 1122 | glUnlockArraysEXT, |
| 1123 | #endif |
| 1124 | |
| 1125 | #ifdef _GLAPI_EXT_point_parameters |
| 1126 | glPointParameterfEXT, |
| 1127 | glPointParameterfvEXT, |
| 1128 | #endif |
| 1129 | |
| 1130 | #ifdef _GLAPI_EXT_polygon_offset |
| 1131 | glPolygonOffsetEXT, |
| 1132 | #endif |
| 1133 | |
| 1134 | #ifdef _GLAPI_EXT_blend_minmax |
| 1135 | glBlendEquationEXT, |
| 1136 | #endif |
| 1137 | |
| 1138 | #ifdef _GLAPI_EXT_blend_color |
| 1139 | glBlendColorEXT, |
| 1140 | #endif |
| 1141 | |
| 1142 | #ifdef _GLAPI_ARB_multitexture |
| 1143 | glActiveTextureARB, |
| 1144 | glClientActiveTextureARB, |
| 1145 | glMultiTexCoord1dARB, |
| 1146 | glMultiTexCoord1dvARB, |
| 1147 | glMultiTexCoord1fARB, |
| 1148 | glMultiTexCoord1fvARB, |
| 1149 | glMultiTexCoord1iARB, |
| 1150 | glMultiTexCoord1ivARB, |
| 1151 | glMultiTexCoord1sARB, |
| 1152 | glMultiTexCoord1svARB, |
| 1153 | glMultiTexCoord2dARB, |
| 1154 | glMultiTexCoord2dvARB, |
| 1155 | glMultiTexCoord2fARB, |
| 1156 | glMultiTexCoord2fvARB, |
| 1157 | glMultiTexCoord2iARB, |
| 1158 | glMultiTexCoord2ivARB, |
| 1159 | glMultiTexCoord2sARB, |
| 1160 | glMultiTexCoord2svARB, |
| 1161 | glMultiTexCoord3dARB, |
| 1162 | glMultiTexCoord3dvARB, |
| 1163 | glMultiTexCoord3fARB, |
| 1164 | glMultiTexCoord3fvARB, |
| 1165 | glMultiTexCoord3iARB, |
| 1166 | glMultiTexCoord3ivARB, |
| 1167 | glMultiTexCoord3sARB, |
| 1168 | glMultiTexCoord3svARB, |
| 1169 | glMultiTexCoord4dARB, |
| 1170 | glMultiTexCoord4dvARB, |
| 1171 | glMultiTexCoord4fARB, |
| 1172 | glMultiTexCoord4fvARB, |
| 1173 | glMultiTexCoord4iARB, |
| 1174 | glMultiTexCoord4ivARB, |
| 1175 | glMultiTexCoord4sARB, |
| 1176 | glMultiTexCoord4svARB, |
| 1177 | #endif |
| 1178 | |
| 1179 | #ifdef _GLAPI_INGR_blend_func_separate |
| 1180 | glBlendFuncSeparateINGR, |
| 1181 | #endif |
| 1182 | |
| 1183 | #ifdef _GLAPI_MESA_window_pos |
| 1184 | glWindowPos4fMESA, |
| 1185 | #endif |
| 1186 | |
| 1187 | #ifdef _GLAPI_MESA_resize_buffers |
| 1188 | glResizeBuffersMESA |
| 1189 | #endif |
| 1190 | |
| 1191 | }; |
| 1192 | |
| 1193 | #endif /*DEBUG*/ |