mesa: Add driver interface for ARB_shader_image_load_store.
[mesa.git] / src / mesa / main / dd.h
1 /**
2 * \file dd.h
3 * Device driver interfaces.
4 */
5
6 /*
7 * Mesa 3-D graphics library
8 *
9 * Copyright (C) 1999-2006 Brian Paul All Rights Reserved.
10 *
11 * Permission is hereby granted, free of charge, to any person obtaining a
12 * copy of this software and associated documentation files (the "Software"),
13 * to deal in the Software without restriction, including without limitation
14 * the rights to use, copy, modify, merge, publish, distribute, sublicense,
15 * and/or sell copies of the Software, and to permit persons to whom the
16 * Software is furnished to do so, subject to the following conditions:
17 *
18 * The above copyright notice and this permission notice shall be included
19 * in all copies or substantial portions of the Software.
20 *
21 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
22 * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
23 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
24 * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR
25 * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
26 * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
27 * OTHER DEALINGS IN THE SOFTWARE.
28 */
29
30
31 #ifndef DD_INCLUDED
32 #define DD_INCLUDED
33
34 /* THIS FILE ONLY INCLUDED BY mtypes.h !!!!! */
35
36 #include "glheader.h"
37
38 struct gl_buffer_object;
39 struct gl_context;
40 struct gl_display_list;
41 struct gl_framebuffer;
42 struct gl_image_unit;
43 struct gl_pixelstore_attrib;
44 struct gl_program;
45 struct gl_renderbuffer;
46 struct gl_renderbuffer_attachment;
47 struct gl_shader;
48 struct gl_shader_program;
49 struct gl_texture_image;
50 struct gl_texture_object;
51
52 /* GL_ARB_vertex_buffer_object */
53 /* Modifies GL_MAP_UNSYNCHRONIZED_BIT to allow driver to fail (return
54 * NULL) if buffer is unavailable for immediate mapping.
55 *
56 * Does GL_MAP_INVALIDATE_RANGE_BIT do this? It seems so, but it
57 * would require more book-keeping in the driver than seems necessary
58 * at this point.
59 *
60 * Does GL_MAP_INVALDIATE_BUFFER_BIT do this? Not really -- we don't
61 * want to provoke the driver to throw away the old storage, we will
62 * respect the contents of already referenced data.
63 */
64 #define MESA_MAP_NOWAIT_BIT 0x0040
65
66
67 /**
68 * Device driver function table.
69 * Core Mesa uses these function pointers to call into device drivers.
70 * Most of these functions directly correspond to OpenGL state commands.
71 * Core Mesa will call these functions after error checking has been done
72 * so that the drivers don't have to worry about error testing.
73 *
74 * Vertex transformation/clipping/lighting is patched into the T&L module.
75 * Rasterization functions are patched into the swrast module.
76 *
77 * Note: when new functions are added here, the drivers/common/driverfuncs.c
78 * file should be updated too!!!
79 */
80 struct dd_function_table {
81 /**
82 * Return a string as needed by glGetString().
83 * Only the GL_RENDERER query must be implemented. Otherwise, NULL can be
84 * returned.
85 */
86 const GLubyte * (*GetString)( struct gl_context *ctx, GLenum name );
87
88 /**
89 * Notify the driver after Mesa has made some internal state changes.
90 *
91 * This is in addition to any state change callbacks Mesa may already have
92 * made.
93 */
94 void (*UpdateState)( struct gl_context *ctx, GLbitfield new_state );
95
96 /**
97 * Resize the given framebuffer to the given size.
98 * XXX OBSOLETE: this function will be removed in the future.
99 */
100 void (*ResizeBuffers)( struct gl_context *ctx, struct gl_framebuffer *fb,
101 GLuint width, GLuint height);
102
103 /**
104 * This is called whenever glFinish() is called.
105 */
106 void (*Finish)( struct gl_context *ctx );
107
108 /**
109 * This is called whenever glFlush() is called.
110 */
111 void (*Flush)( struct gl_context *ctx );
112
113 /**
114 * Clear the color/depth/stencil/accum buffer(s).
115 * \param buffers a bitmask of BUFFER_BIT_* flags indicating which
116 * renderbuffers need to be cleared.
117 */
118 void (*Clear)( struct gl_context *ctx, GLbitfield buffers );
119
120 /**
121 * Execute glAccum command.
122 */
123 void (*Accum)( struct gl_context *ctx, GLenum op, GLfloat value );
124
125
126 /**
127 * Execute glRasterPos, updating the ctx->Current.Raster fields
128 */
129 void (*RasterPos)( struct gl_context *ctx, const GLfloat v[4] );
130
131 /**
132 * \name Image-related functions
133 */
134 /*@{*/
135
136 /**
137 * Called by glDrawPixels().
138 * \p unpack describes how to unpack the source image data.
139 */
140 void (*DrawPixels)( struct gl_context *ctx,
141 GLint x, GLint y, GLsizei width, GLsizei height,
142 GLenum format, GLenum type,
143 const struct gl_pixelstore_attrib *unpack,
144 const GLvoid *pixels );
145
146 /**
147 * Called by glReadPixels().
148 */
149 void (*ReadPixels)( struct gl_context *ctx,
150 GLint x, GLint y, GLsizei width, GLsizei height,
151 GLenum format, GLenum type,
152 const struct gl_pixelstore_attrib *unpack,
153 GLvoid *dest );
154
155 /**
156 * Called by glCopyPixels().
157 */
158 void (*CopyPixels)( struct gl_context *ctx, GLint srcx, GLint srcy,
159 GLsizei width, GLsizei height,
160 GLint dstx, GLint dsty, GLenum type );
161
162 /**
163 * Called by glBitmap().
164 */
165 void (*Bitmap)( struct gl_context *ctx,
166 GLint x, GLint y, GLsizei width, GLsizei height,
167 const struct gl_pixelstore_attrib *unpack,
168 const GLubyte *bitmap );
169 /*@}*/
170
171
172 /**
173 * \name Texture image functions
174 */
175 /*@{*/
176
177 /**
178 * Choose actual hardware texture format given the texture target, the
179 * user-provided source image format and type and the desired internal
180 * format. In some cases, srcFormat and srcType can be GL_NONE.
181 * Note: target may be GL_TEXTURE_CUBE_MAP, but never
182 * GL_TEXTURE_CUBE_MAP_[POSITIVE/NEGATIVE]_[XYZ].
183 * Called by glTexImage(), etc.
184 */
185 gl_format (*ChooseTextureFormat)( struct gl_context *ctx,
186 GLenum target, GLint internalFormat,
187 GLenum srcFormat, GLenum srcType );
188
189 /**
190 * Determine sample counts support for a particular target and format
191 *
192 * \param ctx GL context
193 * \param target GL target enum
194 * \param internalFormat GL format enum
195 * \param samples Buffer to hold the returned sample counts.
196 * Drivers \b must \b not return more than 16 counts.
197 *
198 * \returns
199 * The number of sample counts actually written to \c samples. If
200 * \c internaFormat is not renderable, zero is returned.
201 */
202 size_t (*QuerySamplesForFormat)(struct gl_context *ctx,
203 GLenum target,
204 GLenum internalFormat,
205 int samples[16]);
206
207 /**
208 * Called by glTexImage[123]D() and glCopyTexImage[12]D()
209 * Allocate texture memory and copy the user's image to the buffer.
210 * The gl_texture_image fields, etc. will be fully initialized.
211 * The parameters are the same as glTexImage3D(), plus:
212 * \param dims 1, 2, or 3 indicating glTexImage1/2/3D()
213 * \param packing describes how to unpack the source data.
214 * \param texImage is the destination texture image.
215 */
216 void (*TexImage)(struct gl_context *ctx, GLuint dims,
217 struct gl_texture_image *texImage,
218 GLenum format, GLenum type, const GLvoid *pixels,
219 const struct gl_pixelstore_attrib *packing);
220
221 /**
222 * Called by glTexSubImage[123]D().
223 * Replace a subset of the target texture with new texel data.
224 */
225 void (*TexSubImage)(struct gl_context *ctx, GLuint dims,
226 struct gl_texture_image *texImage,
227 GLint xoffset, GLint yoffset, GLint zoffset,
228 GLsizei width, GLsizei height, GLint depth,
229 GLenum format, GLenum type,
230 const GLvoid *pixels,
231 const struct gl_pixelstore_attrib *packing);
232
233
234 /**
235 * Called by glGetTexImage().
236 */
237 void (*GetTexImage)( struct gl_context *ctx,
238 GLenum format, GLenum type, GLvoid *pixels,
239 struct gl_texture_image *texImage );
240
241 /**
242 * Called by glCopyTex[Sub]Image[123]D().
243 *
244 * This function should copy a rectangular region in the rb to a single
245 * destination slice, specified by @slice. In the case of 1D array
246 * textures (where one GL call can potentially affect multiple destination
247 * slices), core mesa takes care of calling this function multiple times,
248 * once for each scanline to be copied.
249 */
250 void (*CopyTexSubImage)(struct gl_context *ctx, GLuint dims,
251 struct gl_texture_image *texImage,
252 GLint xoffset, GLint yoffset, GLint slice,
253 struct gl_renderbuffer *rb,
254 GLint x, GLint y,
255 GLsizei width, GLsizei height);
256
257 /**
258 * Called by glGenerateMipmap() or when GL_GENERATE_MIPMAP_SGIS is enabled.
259 */
260 void (*GenerateMipmap)(struct gl_context *ctx, GLenum target,
261 struct gl_texture_object *texObj);
262
263 /**
264 * Called by glTexImage, glCompressedTexImage, glCopyTexImage
265 * and glTexStorage to check if the dimensions of the texture image
266 * are too large.
267 * \param target any GL_PROXY_TEXTURE_x target
268 * \return GL_TRUE if the image is OK, GL_FALSE if too large
269 */
270 GLboolean (*TestProxyTexImage)(struct gl_context *ctx, GLenum target,
271 GLint level, gl_format format,
272 GLint width, GLint height,
273 GLint depth, GLint border);
274 /*@}*/
275
276
277 /**
278 * \name Compressed texture functions
279 */
280 /*@{*/
281
282 /**
283 * Called by glCompressedTexImage[123]D().
284 */
285 void (*CompressedTexImage)(struct gl_context *ctx, GLuint dims,
286 struct gl_texture_image *texImage,
287 GLsizei imageSize, const GLvoid *data);
288
289 /**
290 * Called by glCompressedTexSubImage[123]D().
291 */
292 void (*CompressedTexSubImage)(struct gl_context *ctx, GLuint dims,
293 struct gl_texture_image *texImage,
294 GLint xoffset, GLint yoffset, GLint zoffset,
295 GLsizei width, GLint height, GLint depth,
296 GLenum format,
297 GLsizei imageSize, const GLvoid *data);
298
299 /**
300 * Called by glGetCompressedTexImage.
301 */
302 void (*GetCompressedTexImage)(struct gl_context *ctx,
303 struct gl_texture_image *texImage,
304 GLvoid *data);
305 /*@}*/
306
307 /**
308 * \name Texture object / image functions
309 */
310 /*@{*/
311
312 /**
313 * Called by glBindTexture().
314 */
315 void (*BindTexture)( struct gl_context *ctx, GLenum target,
316 struct gl_texture_object *tObj );
317
318 /**
319 * Called to allocate a new texture object. Drivers will usually
320 * allocate/return a subclass of gl_texture_object.
321 */
322 struct gl_texture_object * (*NewTextureObject)(struct gl_context *ctx,
323 GLuint name, GLenum target);
324 /**
325 * Called to delete/free a texture object. Drivers should free the
326 * object and any image data it contains.
327 */
328 void (*DeleteTexture)(struct gl_context *ctx,
329 struct gl_texture_object *texObj);
330
331 /** Called to allocate a new texture image object. */
332 struct gl_texture_image * (*NewTextureImage)(struct gl_context *ctx);
333
334 /** Called to free a texture image object returned by NewTextureImage() */
335 void (*DeleteTextureImage)(struct gl_context *ctx,
336 struct gl_texture_image *);
337
338 /** Called to allocate memory for a single texture image */
339 GLboolean (*AllocTextureImageBuffer)(struct gl_context *ctx,
340 struct gl_texture_image *texImage);
341
342 /** Free the memory for a single texture image */
343 void (*FreeTextureImageBuffer)(struct gl_context *ctx,
344 struct gl_texture_image *texImage);
345
346 /** Map a slice of a texture image into user space.
347 * Note: for GL_TEXTURE_1D_ARRAY, height must be 1, y must be 0 and slice
348 * indicates the 1D array index.
349 * \param texImage the texture image
350 * \param slice the 3D image slice or array texture slice
351 * \param x, y, w, h region of interest
352 * \param mode bitmask of GL_MAP_READ_BIT, GL_MAP_WRITE_BIT and
353 * GL_MAP_INVALIDATE_RANGE_BIT (if writing)
354 * \param mapOut returns start of mapping of region of interest
355 * \param rowStrideOut returns row stride (in bytes). In the case of a
356 * compressed texture, this is the byte stride between one row of blocks
357 * and another.
358 */
359 void (*MapTextureImage)(struct gl_context *ctx,
360 struct gl_texture_image *texImage,
361 GLuint slice,
362 GLuint x, GLuint y, GLuint w, GLuint h,
363 GLbitfield mode,
364 GLubyte **mapOut, GLint *rowStrideOut);
365
366 void (*UnmapTextureImage)(struct gl_context *ctx,
367 struct gl_texture_image *texImage,
368 GLuint slice);
369
370 /** For GL_ARB_texture_storage. Allocate memory for whole mipmap stack.
371 * All the gl_texture_images in the texture object will have their
372 * dimensions, format, etc. initialized already.
373 */
374 GLboolean (*AllocTextureStorage)(struct gl_context *ctx,
375 struct gl_texture_object *texObj,
376 GLsizei levels, GLsizei width,
377 GLsizei height, GLsizei depth);
378
379 /** Called as part of glTextureView to add views to origTexObj */
380 GLboolean (*TextureView)(struct gl_context *ctx,
381 struct gl_texture_object *texObj,
382 struct gl_texture_object *origTexObj);
383
384 /**
385 * Map a renderbuffer into user space.
386 * \param mode bitmask of GL_MAP_READ_BIT, GL_MAP_WRITE_BIT and
387 * GL_MAP_INVALIDATE_RANGE_BIT (if writing)
388 */
389 void (*MapRenderbuffer)(struct gl_context *ctx,
390 struct gl_renderbuffer *rb,
391 GLuint x, GLuint y, GLuint w, GLuint h,
392 GLbitfield mode,
393 GLubyte **mapOut, GLint *rowStrideOut);
394
395 void (*UnmapRenderbuffer)(struct gl_context *ctx,
396 struct gl_renderbuffer *rb);
397
398 /*@}*/
399
400
401 /**
402 * \name Vertex/fragment program functions
403 */
404 /*@{*/
405 /** Bind a vertex/fragment program */
406 void (*BindProgram)(struct gl_context *ctx, GLenum target, struct gl_program *prog);
407 /** Allocate a new program */
408 struct gl_program * (*NewProgram)(struct gl_context *ctx, GLenum target, GLuint id);
409 /** Delete a program */
410 void (*DeleteProgram)(struct gl_context *ctx, struct gl_program *prog);
411 /**
412 * Notify driver that a program string (and GPU code) has been specified
413 * or modified. Return GL_TRUE or GL_FALSE to indicate if the program is
414 * supported by the driver.
415 */
416 GLboolean (*ProgramStringNotify)(struct gl_context *ctx, GLenum target,
417 struct gl_program *prog);
418
419 /**
420 * Notify driver that the sampler uniforms for the current program have
421 * changed. On some drivers, this may require shader recompiles.
422 */
423 void (*SamplerUniformChange)(struct gl_context *ctx, GLenum target,
424 struct gl_program *prog);
425
426 /** Query if program can be loaded onto hardware */
427 GLboolean (*IsProgramNative)(struct gl_context *ctx, GLenum target,
428 struct gl_program *prog);
429
430 /*@}*/
431
432 /**
433 * \name GLSL shader/program functions.
434 */
435 /*@{*/
436 /**
437 * Called when a shader program is linked.
438 *
439 * This gives drivers an opportunity to clone the IR and make their
440 * own transformations on it for the purposes of code generation.
441 */
442 GLboolean (*LinkShader)(struct gl_context *ctx, struct gl_shader_program *shader);
443 /*@}*/
444
445 /**
446 * \name State-changing functions.
447 *
448 * \note drawing functions are above.
449 *
450 * These functions are called by their corresponding OpenGL API functions.
451 * They are \e also called by the gl_PopAttrib() function!!!
452 * May add more functions like these to the device driver in the future.
453 */
454 /*@{*/
455 /** Specify the alpha test function */
456 void (*AlphaFunc)(struct gl_context *ctx, GLenum func, GLfloat ref);
457 /** Set the blend color */
458 void (*BlendColor)(struct gl_context *ctx, const GLfloat color[4]);
459 /** Set the blend equation */
460 void (*BlendEquationSeparate)(struct gl_context *ctx, GLenum modeRGB, GLenum modeA);
461 void (*BlendEquationSeparatei)(struct gl_context *ctx, GLuint buffer,
462 GLenum modeRGB, GLenum modeA);
463 /** Specify pixel arithmetic */
464 void (*BlendFuncSeparate)(struct gl_context *ctx,
465 GLenum sfactorRGB, GLenum dfactorRGB,
466 GLenum sfactorA, GLenum dfactorA);
467 void (*BlendFuncSeparatei)(struct gl_context *ctx, GLuint buffer,
468 GLenum sfactorRGB, GLenum dfactorRGB,
469 GLenum sfactorA, GLenum dfactorA);
470 /** Specify a plane against which all geometry is clipped */
471 void (*ClipPlane)(struct gl_context *ctx, GLenum plane, const GLfloat *equation );
472 /** Enable and disable writing of frame buffer color components */
473 void (*ColorMask)(struct gl_context *ctx, GLboolean rmask, GLboolean gmask,
474 GLboolean bmask, GLboolean amask );
475 void (*ColorMaskIndexed)(struct gl_context *ctx, GLuint buf, GLboolean rmask,
476 GLboolean gmask, GLboolean bmask, GLboolean amask);
477 /** Cause a material color to track the current color */
478 void (*ColorMaterial)(struct gl_context *ctx, GLenum face, GLenum mode);
479 /** Specify whether front- or back-facing facets can be culled */
480 void (*CullFace)(struct gl_context *ctx, GLenum mode);
481 /** Define front- and back-facing polygons */
482 void (*FrontFace)(struct gl_context *ctx, GLenum mode);
483 /** Specify the value used for depth buffer comparisons */
484 void (*DepthFunc)(struct gl_context *ctx, GLenum func);
485 /** Enable or disable writing into the depth buffer */
486 void (*DepthMask)(struct gl_context *ctx, GLboolean flag);
487 /** Specify mapping of depth values from NDC to window coordinates */
488 void (*DepthRange)(struct gl_context *ctx, GLclampd nearval, GLclampd farval);
489 /** Specify the current buffer for writing */
490 void (*DrawBuffer)( struct gl_context *ctx, GLenum buffer );
491 /** Specify the buffers for writing for fragment programs*/
492 void (*DrawBuffers)( struct gl_context *ctx, GLsizei n, const GLenum *buffers );
493 /** Enable or disable server-side gl capabilities */
494 void (*Enable)(struct gl_context *ctx, GLenum cap, GLboolean state);
495 /** Specify fog parameters */
496 void (*Fogfv)(struct gl_context *ctx, GLenum pname, const GLfloat *params);
497 /** Specify implementation-specific hints */
498 void (*Hint)(struct gl_context *ctx, GLenum target, GLenum mode);
499 /** Set light source parameters.
500 * Note: for GL_POSITION and GL_SPOT_DIRECTION, params will have already
501 * been transformed to eye-space.
502 */
503 void (*Lightfv)(struct gl_context *ctx, GLenum light,
504 GLenum pname, const GLfloat *params );
505 /** Set the lighting model parameters */
506 void (*LightModelfv)(struct gl_context *ctx, GLenum pname, const GLfloat *params);
507 /** Specify the line stipple pattern */
508 void (*LineStipple)(struct gl_context *ctx, GLint factor, GLushort pattern );
509 /** Specify the width of rasterized lines */
510 void (*LineWidth)(struct gl_context *ctx, GLfloat width);
511 /** Specify a logical pixel operation for color index rendering */
512 void (*LogicOpcode)(struct gl_context *ctx, GLenum opcode);
513 void (*PointParameterfv)(struct gl_context *ctx, GLenum pname,
514 const GLfloat *params);
515 /** Specify the diameter of rasterized points */
516 void (*PointSize)(struct gl_context *ctx, GLfloat size);
517 /** Select a polygon rasterization mode */
518 void (*PolygonMode)(struct gl_context *ctx, GLenum face, GLenum mode);
519 /** Set the scale and units used to calculate depth values */
520 void (*PolygonOffset)(struct gl_context *ctx, GLfloat factor, GLfloat units);
521 /** Set the polygon stippling pattern */
522 void (*PolygonStipple)(struct gl_context *ctx, const GLubyte *mask );
523 /* Specifies the current buffer for reading */
524 void (*ReadBuffer)( struct gl_context *ctx, GLenum buffer );
525 /** Set rasterization mode */
526 void (*RenderMode)(struct gl_context *ctx, GLenum mode );
527 /** Define the scissor box */
528 void (*Scissor)(struct gl_context *ctx, GLint x, GLint y, GLsizei w, GLsizei h);
529 /** Select flat or smooth shading */
530 void (*ShadeModel)(struct gl_context *ctx, GLenum mode);
531 /** OpenGL 2.0 two-sided StencilFunc */
532 void (*StencilFuncSeparate)(struct gl_context *ctx, GLenum face, GLenum func,
533 GLint ref, GLuint mask);
534 /** OpenGL 2.0 two-sided StencilMask */
535 void (*StencilMaskSeparate)(struct gl_context *ctx, GLenum face, GLuint mask);
536 /** OpenGL 2.0 two-sided StencilOp */
537 void (*StencilOpSeparate)(struct gl_context *ctx, GLenum face, GLenum fail,
538 GLenum zfail, GLenum zpass);
539 /** Control the generation of texture coordinates */
540 void (*TexGen)(struct gl_context *ctx, GLenum coord, GLenum pname,
541 const GLfloat *params);
542 /** Set texture environment parameters */
543 void (*TexEnv)(struct gl_context *ctx, GLenum target, GLenum pname,
544 const GLfloat *param);
545 /** Set texture parameters */
546 void (*TexParameter)(struct gl_context *ctx, GLenum target,
547 struct gl_texture_object *texObj,
548 GLenum pname, const GLfloat *params);
549 /** Set the viewport */
550 void (*Viewport)(struct gl_context *ctx, GLint x, GLint y, GLsizei w, GLsizei h);
551 /*@}*/
552
553
554 /**
555 * \name Vertex/pixel buffer object functions
556 */
557 /*@{*/
558 void (*BindBuffer)( struct gl_context *ctx, GLenum target,
559 struct gl_buffer_object *obj );
560
561 struct gl_buffer_object * (*NewBufferObject)( struct gl_context *ctx, GLuint buffer,
562 GLenum target );
563
564 void (*DeleteBuffer)( struct gl_context *ctx, struct gl_buffer_object *obj );
565
566 GLboolean (*BufferData)( struct gl_context *ctx, GLenum target, GLsizeiptrARB size,
567 const GLvoid *data, GLenum usage,
568 struct gl_buffer_object *obj );
569
570 void (*BufferSubData)( struct gl_context *ctx, GLintptrARB offset,
571 GLsizeiptrARB size, const GLvoid *data,
572 struct gl_buffer_object *obj );
573
574 void (*GetBufferSubData)( struct gl_context *ctx,
575 GLintptrARB offset, GLsizeiptrARB size,
576 GLvoid *data, struct gl_buffer_object *obj );
577
578 void (*ClearBufferSubData)( struct gl_context *ctx,
579 GLintptr offset, GLsizeiptr size,
580 const GLvoid *clearValue,
581 GLsizeiptr clearValueSize,
582 struct gl_buffer_object *obj );
583
584 void (*CopyBufferSubData)( struct gl_context *ctx,
585 struct gl_buffer_object *src,
586 struct gl_buffer_object *dst,
587 GLintptr readOffset, GLintptr writeOffset,
588 GLsizeiptr size );
589
590 /* Returns pointer to the start of the mapped range.
591 * May return NULL if MESA_MAP_NOWAIT_BIT is set in access:
592 */
593 void * (*MapBufferRange)( struct gl_context *ctx, GLintptr offset,
594 GLsizeiptr length, GLbitfield access,
595 struct gl_buffer_object *obj);
596
597 void (*FlushMappedBufferRange)(struct gl_context *ctx,
598 GLintptr offset, GLsizeiptr length,
599 struct gl_buffer_object *obj);
600
601 GLboolean (*UnmapBuffer)( struct gl_context *ctx,
602 struct gl_buffer_object *obj );
603 /*@}*/
604
605 /**
606 * \name Functions for GL_APPLE_object_purgeable
607 */
608 /*@{*/
609 /* variations on ObjectPurgeable */
610 GLenum (*BufferObjectPurgeable)( struct gl_context *ctx, struct gl_buffer_object *obj, GLenum option );
611 GLenum (*RenderObjectPurgeable)( struct gl_context *ctx, struct gl_renderbuffer *obj, GLenum option );
612 GLenum (*TextureObjectPurgeable)( struct gl_context *ctx, struct gl_texture_object *obj, GLenum option );
613
614 /* variations on ObjectUnpurgeable */
615 GLenum (*BufferObjectUnpurgeable)( struct gl_context *ctx, struct gl_buffer_object *obj, GLenum option );
616 GLenum (*RenderObjectUnpurgeable)( struct gl_context *ctx, struct gl_renderbuffer *obj, GLenum option );
617 GLenum (*TextureObjectUnpurgeable)( struct gl_context *ctx, struct gl_texture_object *obj, GLenum option );
618 /*@}*/
619
620 /**
621 * \name Functions for GL_EXT_framebuffer_{object,blit,discard}.
622 */
623 /*@{*/
624 struct gl_framebuffer * (*NewFramebuffer)(struct gl_context *ctx, GLuint name);
625 struct gl_renderbuffer * (*NewRenderbuffer)(struct gl_context *ctx, GLuint name);
626 void (*BindFramebuffer)(struct gl_context *ctx, GLenum target,
627 struct gl_framebuffer *drawFb,
628 struct gl_framebuffer *readFb);
629 void (*FramebufferRenderbuffer)(struct gl_context *ctx,
630 struct gl_framebuffer *fb,
631 GLenum attachment,
632 struct gl_renderbuffer *rb);
633 void (*RenderTexture)(struct gl_context *ctx,
634 struct gl_framebuffer *fb,
635 struct gl_renderbuffer_attachment *att);
636 void (*FinishRenderTexture)(struct gl_context *ctx,
637 struct gl_renderbuffer *rb);
638 void (*ValidateFramebuffer)(struct gl_context *ctx,
639 struct gl_framebuffer *fb);
640 /*@}*/
641 void (*BlitFramebuffer)(struct gl_context *ctx,
642 GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1,
643 GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1,
644 GLbitfield mask, GLenum filter);
645 void (*DiscardFramebuffer)(struct gl_context *ctx,
646 GLenum target, GLsizei numAttachments, const GLenum *attachments);
647
648 /**
649 * \name Query objects
650 */
651 /*@{*/
652 struct gl_query_object * (*NewQueryObject)(struct gl_context *ctx, GLuint id);
653 void (*DeleteQuery)(struct gl_context *ctx, struct gl_query_object *q);
654 void (*BeginQuery)(struct gl_context *ctx, struct gl_query_object *q);
655 void (*QueryCounter)(struct gl_context *ctx, struct gl_query_object *q);
656 void (*EndQuery)(struct gl_context *ctx, struct gl_query_object *q);
657 void (*CheckQuery)(struct gl_context *ctx, struct gl_query_object *q);
658 void (*WaitQuery)(struct gl_context *ctx, struct gl_query_object *q);
659 /*@}*/
660
661 /**
662 * \name Performance monitors
663 */
664 /*@{*/
665 struct gl_perf_monitor_object * (*NewPerfMonitor)(struct gl_context *ctx);
666 void (*DeletePerfMonitor)(struct gl_context *ctx,
667 struct gl_perf_monitor_object *m);
668 GLboolean (*BeginPerfMonitor)(struct gl_context *ctx,
669 struct gl_perf_monitor_object *m);
670
671 /** Stop an active performance monitor, discarding results. */
672 void (*ResetPerfMonitor)(struct gl_context *ctx,
673 struct gl_perf_monitor_object *m);
674 void (*EndPerfMonitor)(struct gl_context *ctx,
675 struct gl_perf_monitor_object *m);
676 GLboolean (*IsPerfMonitorResultAvailable)(struct gl_context *ctx,
677 struct gl_perf_monitor_object *m);
678 void (*GetPerfMonitorResult)(struct gl_context *ctx,
679 struct gl_perf_monitor_object *m,
680 GLsizei dataSize,
681 GLuint *data,
682 GLint *bytesWritten);
683 /*@}*/
684
685
686 /**
687 * \name Vertex Array objects
688 */
689 /*@{*/
690 struct gl_array_object * (*NewArrayObject)(struct gl_context *ctx, GLuint id);
691 void (*DeleteArrayObject)(struct gl_context *ctx, struct gl_array_object *obj);
692 void (*BindArrayObject)(struct gl_context *ctx, struct gl_array_object *obj);
693 /*@}*/
694
695 /**
696 * \name GLSL-related functions (ARB extensions and OpenGL 2.x)
697 */
698 /*@{*/
699 struct gl_shader *(*NewShader)(struct gl_context *ctx, GLuint name, GLenum type);
700 void (*DeleteShader)(struct gl_context *ctx, struct gl_shader *shader);
701 struct gl_shader_program *(*NewShaderProgram)(struct gl_context *ctx, GLuint name);
702 void (*DeleteShaderProgram)(struct gl_context *ctx,
703 struct gl_shader_program *shProg);
704 void (*UseProgram)(struct gl_context *ctx, struct gl_shader_program *shProg);
705 /*@}*/
706
707
708 /**
709 * \name Support for multiple T&L engines
710 */
711 /*@{*/
712
713 /**
714 * Set by the driver-supplied T&L engine.
715 *
716 * Set to PRIM_OUTSIDE_BEGIN_END when outside glBegin()/glEnd().
717 */
718 GLuint CurrentExecPrimitive;
719
720 /**
721 * Current glBegin state of an in-progress compilation. May be
722 * GL_POINTS, GL_TRIANGLE_STRIP, etc. or PRIM_OUTSIDE_BEGIN_END
723 * or PRIM_UNKNOWN.
724 */
725 GLuint CurrentSavePrimitive;
726
727
728 #define FLUSH_STORED_VERTICES 0x1
729 #define FLUSH_UPDATE_CURRENT 0x2
730 /**
731 * Set by the driver-supplied T&L engine whenever vertices are buffered
732 * between glBegin()/glEnd() objects or __struct gl_contextRec::Current
733 * is not updated. A bitmask of the FLUSH_x values above.
734 *
735 * The dd_function_table::FlushVertices call below may be used to resolve
736 * these conditions.
737 */
738 GLbitfield NeedFlush;
739
740 /** Need to call SaveFlushVertices() upon state change? */
741 GLboolean SaveNeedFlush;
742
743 /* Called prior to any of the GLvertexformat functions being
744 * called. Paired with Driver.FlushVertices().
745 */
746 void (*BeginVertices)( struct gl_context *ctx );
747
748 /**
749 * If inside glBegin()/glEnd(), it should ASSERT(0). Otherwise, if
750 * FLUSH_STORED_VERTICES bit in \p flags is set flushes any buffered
751 * vertices, if FLUSH_UPDATE_CURRENT bit is set updates
752 * __struct gl_contextRec::Current and gl_light_attrib::Material
753 *
754 * Note that the default T&L engine never clears the
755 * FLUSH_UPDATE_CURRENT bit, even after performing the update.
756 */
757 void (*FlushVertices)( struct gl_context *ctx, GLuint flags );
758 void (*SaveFlushVertices)( struct gl_context *ctx );
759
760 /**
761 * Give the driver the opportunity to hook in its own vtxfmt for
762 * compiling optimized display lists. This is called on each valid
763 * glBegin() during list compilation.
764 */
765 GLboolean (*NotifySaveBegin)( struct gl_context *ctx, GLenum mode );
766
767 /**
768 * Notify driver that the special derived value _NeedEyeCoords has
769 * changed.
770 */
771 void (*LightingSpaceChange)( struct gl_context *ctx );
772
773 /**
774 * Called by glNewList().
775 *
776 * Let the T&L component know what is going on with display lists
777 * in time to make changes to dispatch tables, etc.
778 */
779 void (*NewList)( struct gl_context *ctx, GLuint list, GLenum mode );
780 /**
781 * Called by glEndList().
782 *
783 * \sa dd_function_table::NewList.
784 */
785 void (*EndList)( struct gl_context *ctx );
786
787 /**
788 * Called by glCallList(s).
789 *
790 * Notify the T&L component before and after calling a display list.
791 */
792 void (*BeginCallList)( struct gl_context *ctx,
793 struct gl_display_list *dlist );
794 /**
795 * Called by glEndCallList().
796 *
797 * \sa dd_function_table::BeginCallList.
798 */
799 void (*EndCallList)( struct gl_context *ctx );
800
801 /**@}*/
802
803 /**
804 * \name GL_ARB_sync interfaces
805 */
806 /*@{*/
807 struct gl_sync_object * (*NewSyncObject)(struct gl_context *, GLenum);
808 void (*FenceSync)(struct gl_context *, struct gl_sync_object *, GLenum, GLbitfield);
809 void (*DeleteSyncObject)(struct gl_context *, struct gl_sync_object *);
810 void (*CheckSync)(struct gl_context *, struct gl_sync_object *);
811 void (*ClientWaitSync)(struct gl_context *, struct gl_sync_object *,
812 GLbitfield, GLuint64);
813 void (*ServerWaitSync)(struct gl_context *, struct gl_sync_object *,
814 GLbitfield, GLuint64);
815 /*@}*/
816
817 /** GL_NV_conditional_render */
818 void (*BeginConditionalRender)(struct gl_context *ctx, struct gl_query_object *q,
819 GLenum mode);
820 void (*EndConditionalRender)(struct gl_context *ctx, struct gl_query_object *q);
821
822 /**
823 * \name GL_OES_draw_texture interface
824 */
825 /*@{*/
826 void (*DrawTex)(struct gl_context *ctx, GLfloat x, GLfloat y, GLfloat z,
827 GLfloat width, GLfloat height);
828 /*@}*/
829
830 /**
831 * \name GL_OES_EGL_image interface
832 */
833 void (*EGLImageTargetTexture2D)(struct gl_context *ctx, GLenum target,
834 struct gl_texture_object *texObj,
835 struct gl_texture_image *texImage,
836 GLeglImageOES image_handle);
837 void (*EGLImageTargetRenderbufferStorage)(struct gl_context *ctx,
838 struct gl_renderbuffer *rb,
839 void *image_handle);
840
841 /**
842 * \name GL_EXT_transform_feedback interface
843 */
844 struct gl_transform_feedback_object *
845 (*NewTransformFeedback)(struct gl_context *ctx, GLuint name);
846 void (*DeleteTransformFeedback)(struct gl_context *ctx,
847 struct gl_transform_feedback_object *obj);
848 void (*BeginTransformFeedback)(struct gl_context *ctx, GLenum mode,
849 struct gl_transform_feedback_object *obj);
850 void (*EndTransformFeedback)(struct gl_context *ctx,
851 struct gl_transform_feedback_object *obj);
852 void (*PauseTransformFeedback)(struct gl_context *ctx,
853 struct gl_transform_feedback_object *obj);
854 void (*ResumeTransformFeedback)(struct gl_context *ctx,
855 struct gl_transform_feedback_object *obj);
856
857 /**
858 * Return the number of vertices written to a stream during the last
859 * Begin/EndTransformFeedback block.
860 */
861 GLsizei (*GetTransformFeedbackVertexCount)(struct gl_context *ctx,
862 struct gl_transform_feedback_object *obj,
863 GLuint stream);
864
865 /**
866 * \name GL_NV_texture_barrier interface
867 */
868 void (*TextureBarrier)(struct gl_context *ctx);
869
870 /**
871 * \name GL_ARB_sampler_objects
872 */
873 struct gl_sampler_object * (*NewSamplerObject)(struct gl_context *ctx,
874 GLuint name);
875 void (*DeleteSamplerObject)(struct gl_context *ctx,
876 struct gl_sampler_object *samp);
877
878 /**
879 * \name Return a timestamp in nanoseconds as defined by GL_ARB_timer_query.
880 * This should be equivalent to glGetInteger64v(GL_TIMESTAMP);
881 */
882 uint64_t (*GetTimestamp)(struct gl_context *ctx);
883
884 /**
885 * \name GL_ARB_texture_multisample
886 */
887 void (*GetSamplePosition)(struct gl_context *ctx,
888 struct gl_framebuffer *fb,
889 GLuint index,
890 GLfloat *outValue);
891
892 /**
893 * \name NV_vdpau_interop interface
894 */
895 void (*VDPAUMapSurface)(struct gl_context *ctx, GLenum target,
896 GLenum access, GLboolean output,
897 struct gl_texture_object *texObj,
898 struct gl_texture_image *texImage,
899 const GLvoid *vdpSurface, GLuint index);
900 void (*VDPAUUnmapSurface)(struct gl_context *ctx, GLenum target,
901 GLenum access, GLboolean output,
902 struct gl_texture_object *texObj,
903 struct gl_texture_image *texImage,
904 const GLvoid *vdpSurface, GLuint index);
905
906 /**
907 * Query reset status for GL_ARB_robustness
908 *
909 * Per \c glGetGraphicsResetStatusARB, this function should return a
910 * non-zero value once after a reset. If a reset is non-atomic, the
911 * non-zero status should be returned for the duration of the reset.
912 */
913 GLenum (*GetGraphicsResetStatus)(struct gl_context *ctx);
914
915 /**
916 * \name GL_ARB_shader_image_load_store interface.
917 */
918 /** @{ */
919 void (*BindImageTexture)(struct gl_context *ctx,
920 struct gl_image_unit *unit,
921 struct gl_texture_object *texObj,
922 GLint level, GLboolean layered, GLint layer,
923 GLenum access, GLenum format);
924
925 void (*MemoryBarrier)(struct gl_context *ctx, GLbitfield barriers);
926 /** @} */
927 };
928
929
930 /**
931 * Per-vertex functions.
932 *
933 * These are the functions which can appear between glBegin and glEnd.
934 * Depending on whether we're inside or outside a glBegin/End pair
935 * and whether we're in immediate mode or building a display list, these
936 * functions behave differently. This structure allows us to switch
937 * between those modes more easily.
938 *
939 * Generally, these pointers point to functions in the VBO module.
940 */
941 typedef struct {
942 void (GLAPIENTRYP ArrayElement)( GLint );
943 void (GLAPIENTRYP Color3f)( GLfloat, GLfloat, GLfloat );
944 void (GLAPIENTRYP Color3fv)( const GLfloat * );
945 void (GLAPIENTRYP Color4f)( GLfloat, GLfloat, GLfloat, GLfloat );
946 void (GLAPIENTRYP Color4fv)( const GLfloat * );
947 void (GLAPIENTRYP EdgeFlag)( GLboolean );
948 void (GLAPIENTRYP EvalCoord1f)( GLfloat );
949 void (GLAPIENTRYP EvalCoord1fv)( const GLfloat * );
950 void (GLAPIENTRYP EvalCoord2f)( GLfloat, GLfloat );
951 void (GLAPIENTRYP EvalCoord2fv)( const GLfloat * );
952 void (GLAPIENTRYP EvalPoint1)( GLint );
953 void (GLAPIENTRYP EvalPoint2)( GLint, GLint );
954 void (GLAPIENTRYP FogCoordfEXT)( GLfloat );
955 void (GLAPIENTRYP FogCoordfvEXT)( const GLfloat * );
956 void (GLAPIENTRYP Indexf)( GLfloat );
957 void (GLAPIENTRYP Indexfv)( const GLfloat * );
958 void (GLAPIENTRYP Materialfv)( GLenum face, GLenum pname, const GLfloat * );
959 void (GLAPIENTRYP MultiTexCoord1fARB)( GLenum, GLfloat );
960 void (GLAPIENTRYP MultiTexCoord1fvARB)( GLenum, const GLfloat * );
961 void (GLAPIENTRYP MultiTexCoord2fARB)( GLenum, GLfloat, GLfloat );
962 void (GLAPIENTRYP MultiTexCoord2fvARB)( GLenum, const GLfloat * );
963 void (GLAPIENTRYP MultiTexCoord3fARB)( GLenum, GLfloat, GLfloat, GLfloat );
964 void (GLAPIENTRYP MultiTexCoord3fvARB)( GLenum, const GLfloat * );
965 void (GLAPIENTRYP MultiTexCoord4fARB)( GLenum, GLfloat, GLfloat, GLfloat, GLfloat );
966 void (GLAPIENTRYP MultiTexCoord4fvARB)( GLenum, const GLfloat * );
967 void (GLAPIENTRYP Normal3f)( GLfloat, GLfloat, GLfloat );
968 void (GLAPIENTRYP Normal3fv)( const GLfloat * );
969 void (GLAPIENTRYP SecondaryColor3fEXT)( GLfloat, GLfloat, GLfloat );
970 void (GLAPIENTRYP SecondaryColor3fvEXT)( const GLfloat * );
971 void (GLAPIENTRYP TexCoord1f)( GLfloat );
972 void (GLAPIENTRYP TexCoord1fv)( const GLfloat * );
973 void (GLAPIENTRYP TexCoord2f)( GLfloat, GLfloat );
974 void (GLAPIENTRYP TexCoord2fv)( const GLfloat * );
975 void (GLAPIENTRYP TexCoord3f)( GLfloat, GLfloat, GLfloat );
976 void (GLAPIENTRYP TexCoord3fv)( const GLfloat * );
977 void (GLAPIENTRYP TexCoord4f)( GLfloat, GLfloat, GLfloat, GLfloat );
978 void (GLAPIENTRYP TexCoord4fv)( const GLfloat * );
979 void (GLAPIENTRYP Vertex2f)( GLfloat, GLfloat );
980 void (GLAPIENTRYP Vertex2fv)( const GLfloat * );
981 void (GLAPIENTRYP Vertex3f)( GLfloat, GLfloat, GLfloat );
982 void (GLAPIENTRYP Vertex3fv)( const GLfloat * );
983 void (GLAPIENTRYP Vertex4f)( GLfloat, GLfloat, GLfloat, GLfloat );
984 void (GLAPIENTRYP Vertex4fv)( const GLfloat * );
985 void (GLAPIENTRYP CallList)( GLuint );
986 void (GLAPIENTRYP CallLists)( GLsizei, GLenum, const GLvoid * );
987 void (GLAPIENTRYP Begin)( GLenum );
988 void (GLAPIENTRYP End)( void );
989 void (GLAPIENTRYP PrimitiveRestartNV)( void );
990 /* Originally for GL_NV_vertex_program, now used only dlist.c and friends */
991 void (GLAPIENTRYP VertexAttrib1fNV)( GLuint index, GLfloat x );
992 void (GLAPIENTRYP VertexAttrib1fvNV)( GLuint index, const GLfloat *v );
993 void (GLAPIENTRYP VertexAttrib2fNV)( GLuint index, GLfloat x, GLfloat y );
994 void (GLAPIENTRYP VertexAttrib2fvNV)( GLuint index, const GLfloat *v );
995 void (GLAPIENTRYP VertexAttrib3fNV)( GLuint index, GLfloat x, GLfloat y, GLfloat z );
996 void (GLAPIENTRYP VertexAttrib3fvNV)( GLuint index, const GLfloat *v );
997 void (GLAPIENTRYP VertexAttrib4fNV)( GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w );
998 void (GLAPIENTRYP VertexAttrib4fvNV)( GLuint index, const GLfloat *v );
999 /* GL_ARB_vertex_program */
1000 void (GLAPIENTRYP VertexAttrib1fARB)( GLuint index, GLfloat x );
1001 void (GLAPIENTRYP VertexAttrib1fvARB)( GLuint index, const GLfloat *v );
1002 void (GLAPIENTRYP VertexAttrib2fARB)( GLuint index, GLfloat x, GLfloat y );
1003 void (GLAPIENTRYP VertexAttrib2fvARB)( GLuint index, const GLfloat *v );
1004 void (GLAPIENTRYP VertexAttrib3fARB)( GLuint index, GLfloat x, GLfloat y, GLfloat z );
1005 void (GLAPIENTRYP VertexAttrib3fvARB)( GLuint index, const GLfloat *v );
1006 void (GLAPIENTRYP VertexAttrib4fARB)( GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w );
1007 void (GLAPIENTRYP VertexAttrib4fvARB)( GLuint index, const GLfloat *v );
1008
1009 /* GL_EXT_gpu_shader4 / GL 3.0 */
1010 void (GLAPIENTRYP VertexAttribI1i)( GLuint index, GLint x);
1011 void (GLAPIENTRYP VertexAttribI2i)( GLuint index, GLint x, GLint y);
1012 void (GLAPIENTRYP VertexAttribI3i)( GLuint index, GLint x, GLint y, GLint z);
1013 void (GLAPIENTRYP VertexAttribI4i)( GLuint index, GLint x, GLint y, GLint z, GLint w);
1014 void (GLAPIENTRYP VertexAttribI2iv)( GLuint index, const GLint *v);
1015 void (GLAPIENTRYP VertexAttribI3iv)( GLuint index, const GLint *v);
1016 void (GLAPIENTRYP VertexAttribI4iv)( GLuint index, const GLint *v);
1017
1018 void (GLAPIENTRYP VertexAttribI1ui)( GLuint index, GLuint x);
1019 void (GLAPIENTRYP VertexAttribI2ui)( GLuint index, GLuint x, GLuint y);
1020 void (GLAPIENTRYP VertexAttribI3ui)( GLuint index, GLuint x, GLuint y, GLuint z);
1021 void (GLAPIENTRYP VertexAttribI4ui)( GLuint index, GLuint x, GLuint y, GLuint z, GLuint w);
1022 void (GLAPIENTRYP VertexAttribI2uiv)( GLuint index, const GLuint *v);
1023 void (GLAPIENTRYP VertexAttribI3uiv)( GLuint index, const GLuint *v);
1024 void (GLAPIENTRYP VertexAttribI4uiv)( GLuint index, const GLuint *v);
1025
1026 /* GL_ARB_vertex_type_10_10_10_2_rev / GL3.3 */
1027 void (GLAPIENTRYP VertexP2ui)( GLenum type, GLuint value );
1028 void (GLAPIENTRYP VertexP2uiv)( GLenum type, const GLuint *value);
1029
1030 void (GLAPIENTRYP VertexP3ui)( GLenum type, GLuint value );
1031 void (GLAPIENTRYP VertexP3uiv)( GLenum type, const GLuint *value);
1032
1033 void (GLAPIENTRYP VertexP4ui)( GLenum type, GLuint value );
1034 void (GLAPIENTRYP VertexP4uiv)( GLenum type, const GLuint *value);
1035
1036 void (GLAPIENTRYP TexCoordP1ui)( GLenum type, GLuint coords );
1037 void (GLAPIENTRYP TexCoordP1uiv)( GLenum type, const GLuint *coords );
1038
1039 void (GLAPIENTRYP TexCoordP2ui)( GLenum type, GLuint coords );
1040 void (GLAPIENTRYP TexCoordP2uiv)( GLenum type, const GLuint *coords );
1041
1042 void (GLAPIENTRYP TexCoordP3ui)( GLenum type, GLuint coords );
1043 void (GLAPIENTRYP TexCoordP3uiv)( GLenum type, const GLuint *coords );
1044
1045 void (GLAPIENTRYP TexCoordP4ui)( GLenum type, GLuint coords );
1046 void (GLAPIENTRYP TexCoordP4uiv)( GLenum type, const GLuint *coords );
1047
1048 void (GLAPIENTRYP MultiTexCoordP1ui)( GLenum texture, GLenum type, GLuint coords );
1049 void (GLAPIENTRYP MultiTexCoordP1uiv)( GLenum texture, GLenum type, const GLuint *coords );
1050 void (GLAPIENTRYP MultiTexCoordP2ui)( GLenum texture, GLenum type, GLuint coords );
1051 void (GLAPIENTRYP MultiTexCoordP2uiv)( GLenum texture, GLenum type, const GLuint *coords );
1052 void (GLAPIENTRYP MultiTexCoordP3ui)( GLenum texture, GLenum type, GLuint coords );
1053 void (GLAPIENTRYP MultiTexCoordP3uiv)( GLenum texture, GLenum type, const GLuint *coords );
1054 void (GLAPIENTRYP MultiTexCoordP4ui)( GLenum texture, GLenum type, GLuint coords );
1055 void (GLAPIENTRYP MultiTexCoordP4uiv)( GLenum texture, GLenum type, const GLuint *coords );
1056
1057 void (GLAPIENTRYP NormalP3ui)( GLenum type, GLuint coords );
1058 void (GLAPIENTRYP NormalP3uiv)( GLenum type, const GLuint *coords );
1059
1060 void (GLAPIENTRYP ColorP3ui)( GLenum type, GLuint color );
1061 void (GLAPIENTRYP ColorP3uiv)( GLenum type, const GLuint *color );
1062
1063 void (GLAPIENTRYP ColorP4ui)( GLenum type, GLuint color );
1064 void (GLAPIENTRYP ColorP4uiv)( GLenum type, const GLuint *color );
1065
1066 void (GLAPIENTRYP SecondaryColorP3ui)( GLenum type, GLuint color );
1067 void (GLAPIENTRYP SecondaryColorP3uiv)( GLenum type, const GLuint *color );
1068
1069 void (GLAPIENTRYP VertexAttribP1ui)( GLuint index, GLenum type,
1070 GLboolean normalized, GLuint value);
1071 void (GLAPIENTRYP VertexAttribP2ui)( GLuint index, GLenum type,
1072 GLboolean normalized, GLuint value);
1073 void (GLAPIENTRYP VertexAttribP3ui)( GLuint index, GLenum type,
1074 GLboolean normalized, GLuint value);
1075 void (GLAPIENTRYP VertexAttribP4ui)( GLuint index, GLenum type,
1076 GLboolean normalized, GLuint value);
1077 void (GLAPIENTRYP VertexAttribP1uiv)( GLuint index, GLenum type,
1078 GLboolean normalized,
1079 const GLuint *value);
1080 void (GLAPIENTRYP VertexAttribP2uiv)( GLuint index, GLenum type,
1081 GLboolean normalized,
1082 const GLuint *value);
1083 void (GLAPIENTRYP VertexAttribP3uiv)( GLuint index, GLenum type,
1084 GLboolean normalized,
1085 const GLuint *value);
1086 void (GLAPIENTRYP VertexAttribP4uiv)( GLuint index, GLenum type,
1087 GLboolean normalized,
1088 const GLuint *value);
1089 } GLvertexformat;
1090
1091
1092 #endif /* DD_INCLUDED */