summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrian Paul <brian.paul@tungstengraphics.com>2003-09-17 03:33:10 +0000
committerBrian Paul <brian.paul@tungstengraphics.com>2003-09-17 03:33:10 +0000
commitb04633d7270aa326519cd1ce14581df681d708db (patch)
treeb70aaa9d61352317cac4d072cdfe8f17dfffaf6d
parent458c900d3b6fcf9a939884f843e1cadd5be1ed22 (diff)
downloadmesa-b04633d7270aa326519cd1ce14581df681d708db.tar.gz
mesa-b04633d7270aa326519cd1ce14581df681d708db.tar.bz2
mesa-b04633d7270aa326519cd1ce14581df681d708db.zip
move some functions, add some comments
-rw-r--r--src/mesa/main/dd.h72
1 files changed, 40 insertions, 32 deletions
diff --git a/src/mesa/main/dd.h b/src/mesa/main/dd.h
index 09a53e557cc..c6760d4ed90 100644
--- a/src/mesa/main/dd.h
+++ b/src/mesa/main/dd.h
@@ -51,6 +51,13 @@ struct gl_pixelstore_attrib;
/**
* Device driver function table.
+ * Core Mesa uses these function pointers to call into device drivers.
+ * Most of these functions directly correspond to OpenGL state commands.
+ * Core Mesa will call these functions after error checking has been done
+ * so that the drivers don't have to worry about error testing.
+ *
+ * Vertex transformation/clipping/lighting is patched into the T&L module.
+ * Rasterization functions are patched into the swrast module.
*/
struct dd_function_table {
/**
@@ -713,6 +720,39 @@ struct dd_function_table {
/**
+ * \name Vertex buffer object functions
+ */
+#if FEATURE_ARB_vertex_buffer_object
+ /*@{*/
+ void (*BindBuffer)( GLcontext *ctx, GLenum target,
+ struct gl_buffer_object *obj );
+
+ struct gl_buffer_object * (*NewBufferObject)( GLcontext *ctx, GLuint buffer,
+ GLenum target );
+
+ void (*DeleteBuffer)( GLcontext *ctx, struct gl_buffer_object *obj );
+
+ void (*BufferData)( GLcontext *ctx, GLenum target, GLsizeiptrARB size,
+ const GLvoid *data, GLenum usage,
+ struct gl_buffer_object *obj );
+
+ void (*BufferSubData)( GLcontext *ctx, GLenum target, GLintptrARB offset,
+ GLsizeiptrARB size, const GLvoid *data,
+ struct gl_buffer_object *obj );
+
+ void (*GetBufferSubData)( GLcontext *ctx, GLenum target,
+ GLintptrARB offset, GLsizeiptrARB size,
+ GLvoid *data, struct gl_buffer_object *obj );
+
+ void * (*MapBuffer)( GLcontext *ctx, GLenum target, GLenum access,
+ struct gl_buffer_object *obj );
+
+ GLboolean (*UnmapBuffer)( GLcontext *ctx, GLenum target,
+ struct gl_buffer_object *obj );
+ /*@}*/
+#endif
+
+ /**
* \name Support for multiple T&L engines
*/
/*@{*/
@@ -830,38 +870,6 @@ struct dd_function_table {
void (*UnlockArraysEXT)( GLcontext *ctx );
/*@}*/
-
- /**
- * \name Vertex buffer object functions
- */
- /*@{*/
-
- void (*BindBuffer)( GLcontext *ctx, GLenum target,
- struct gl_buffer_object *obj );
-
- struct gl_buffer_object * (*NewBufferObject)( GLcontext *ctx, int buffer,
- GLenum target );
-
- void (*DeleteBuffer)( GLcontext *ctx, struct gl_buffer_object *obj );
-
- void (*BufferData)( GLcontext *ctx, GLenum target, GLsizeiptrARB size,
- const GLvoid *data, GLenum usage,
- struct gl_buffer_object *obj );
-
- void (*BufferSubData)( GLcontext *ctx, GLenum target, GLintptrARB offset,
- GLsizeiptrARB size, const GLvoid *data,
- struct gl_buffer_object *obj );
-
- void (*GetBufferSubData)( GLcontext *ctx, GLenum target,
- GLintptrARB offset, GLsizeiptrARB size,
- GLvoid *data, struct gl_buffer_object *obj );
-
- void * (*MapBuffer)( GLcontext *ctx, GLenum target, GLenum access,
- struct gl_buffer_object *obj );
-
- GLboolean (*UnmapBuffer)( GLcontext *ctx, GLenum target,
- struct gl_buffer_object *obj );
- /*@}*/
};