summaryrefslogtreecommitdiffstats
path: root/src/mesa/main
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2016-10-26 09:33:49 -0700
committerBrian Paul <[email protected]>2016-10-28 09:25:30 -0700
commitc538846e313c43858fb118db012b592513c0ed29 (patch)
tree6135053f2f97c58a680462a523471db4b3095802 /src/mesa/main
parent161db1335b8dd1f3e2a9abbe82d3b8921d2da314 (diff)
mesa: rename gl_client_array -> gl_vertex_array
The term "client array" is a legacy thing dating back to the pre-VBO era when _all_ vertex arrays lived in client memory. Nowadays, it only contains vertex array state which is derived from gl_array_attributes and gl_vertex_buffer_binding. It's used by the VBO module and some drivers. Reviewed-by: Anuj Phogat <[email protected]>
Diffstat (limited to 'src/mesa/main')
-rw-r--r--src/mesa/main/arrayobj.c4
-rw-r--r--src/mesa/main/mtypes.h10
-rw-r--r--src/mesa/main/varray.c4
-rw-r--r--src/mesa/main/varray.h10
4 files changed, 15 insertions, 13 deletions
diff --git a/src/mesa/main/arrayobj.c b/src/mesa/main/arrayobj.c
index a54889bbe1a..ab1b834b6d9 100644
--- a/src/mesa/main/arrayobj.c
+++ b/src/mesa/main/arrayobj.c
@@ -340,7 +340,7 @@ remove_array_object(struct gl_context *ctx, struct gl_vertex_array_object *vao)
/**
- * Updates the derived gl_client_arrays when a gl_vertex_attrib_array
+ * Updates the derived gl_vertex_arrays when a gl_vertex_attrib_array
* or a gl_vertex_buffer_binding has changed.
*/
void
@@ -351,7 +351,7 @@ _mesa_update_vao_client_arrays(struct gl_context *ctx,
while (arrays) {
const int attrib = u_bit_scan64(&arrays);
- struct gl_client_array *client_array = &vao->_VertexAttrib[attrib];
+ struct gl_vertex_array *client_array = &vao->_VertexAttrib[attrib];
const struct gl_array_attributes *attrib_array =
&vao->VertexAttrib[attrib];
const struct gl_vertex_buffer_binding *buffer_binding =
diff --git a/src/mesa/main/mtypes.h b/src/mesa/main/mtypes.h
index 210a161de6f..75764cc4e45 100644
--- a/src/mesa/main/mtypes.h
+++ b/src/mesa/main/mtypes.h
@@ -1332,9 +1332,11 @@ struct gl_pixelstore_attrib
/**
- * Client vertex array attributes
+ * Vertex array information which is derived from gl_array_attributes
+ * and gl_vertex_buffer_binding information. Used by the VBO module and
+ * device drivers.
*/
-struct gl_client_array
+struct gl_vertex_array
{
GLint Size; /**< components per element (1,2,3,4) */
GLenum Type; /**< datatype: GL_FLOAT, GL_INT, etc */
@@ -1439,7 +1441,7 @@ struct gl_vertex_array_object
* This is a legacy data structure created from gl_vertex_attrib_array and
* gl_vertex_buffer_binding, for compatibility with existing driver code.
*/
- struct gl_client_array _VertexAttrib[VERT_ATTRIB_MAX];
+ struct gl_vertex_array _VertexAttrib[VERT_ATTRIB_MAX];
/** Vertex attribute arrays */
struct gl_array_attributes VertexAttrib[VERT_ATTRIB_MAX];
@@ -1530,7 +1532,7 @@ struct gl_array_attrib
* Vertex arrays as consumed by a driver.
* The array pointer is set up only by the VBO module.
*/
- const struct gl_client_array **_DrawArrays; /**< 0..VERT_ATTRIB_MAX-1 */
+ const struct gl_vertex_array **_DrawArrays; /**< 0..VERT_ATTRIB_MAX-1 */
/** Legal array datatypes and the API for which they have been computed */
GLbitfield LegalTypesMask;
diff --git a/src/mesa/main/varray.c b/src/mesa/main/varray.c
index 59f1779b0c5..656cb3479c7 100644
--- a/src/mesa/main/varray.c
+++ b/src/mesa/main/varray.c
@@ -2313,8 +2313,8 @@ _mesa_VertexArrayBindingDivisor(GLuint vaobj, GLuint bindingIndex,
*/
void
_mesa_copy_client_array(struct gl_context *ctx,
- struct gl_client_array *dst,
- struct gl_client_array *src)
+ struct gl_vertex_array *dst,
+ struct gl_vertex_array *src)
{
dst->Size = src->Size;
dst->Type = src->Type;
diff --git a/src/mesa/main/varray.h b/src/mesa/main/varray.h
index bc1c0c6f720..8c30d16ea3a 100644
--- a/src/mesa/main/varray.h
+++ b/src/mesa/main/varray.h
@@ -31,7 +31,7 @@
#include "glheader.h"
#include "bufferobj.h"
-struct gl_client_array;
+struct gl_vertex_array;
struct gl_context;
/**
@@ -50,12 +50,12 @@ _mesa_vertex_attrib_address(const struct gl_array_attributes *array,
}
/**
- * Sets the fields in a gl_client_array to values derived from a
+ * Sets the fields in a gl_vertex_array to values derived from a
* gl_vertex_attrib_array and a gl_vertex_buffer_binding.
*/
static inline void
_mesa_update_client_array(struct gl_context *ctx,
- struct gl_client_array *dst,
+ struct gl_vertex_array *dst,
const struct gl_array_attributes *src,
const struct gl_vertex_buffer_binding *binding)
{
@@ -373,8 +373,8 @@ _mesa_VertexArrayBindingDivisor(GLuint vaobj, GLuint bindingIndex, GLuint diviso
extern void
_mesa_copy_client_array(struct gl_context *ctx,
- struct gl_client_array *dst,
- struct gl_client_array *src);
+ struct gl_vertex_array *dst,
+ struct gl_vertex_array *src);
extern void
_mesa_copy_vertex_attrib_array(struct gl_context *ctx,