projects
/
mesa.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
st/mesa: simplify the signature of get_client_array
[mesa.git]
/
src
/
mesa
/
vbo
/
vbo_rebase.c
diff --git
a/src/mesa/vbo/vbo_rebase.c
b/src/mesa/vbo/vbo_rebase.c
index b06df4ab276266353a0fd16ba3e20c51aa3a1e0e..9f5dc4678f8d59187c82bb568aaed8591d1fcdbc 100644
(file)
--- a/
src/mesa/vbo/vbo_rebase.c
+++ b/
src/mesa/vbo/vbo_rebase.c
@@
-79,7
+79,7
@@
REBASE(GLuint)
REBASE(GLushort)
REBASE(GLubyte)
REBASE(GLushort)
REBASE(GLubyte)
-GLboolean vbo_all_varyings_in_vbos( const struct gl_
client
_array *arrays[] )
+GLboolean vbo_all_varyings_in_vbos( const struct gl_
vertex
_array *arrays[] )
{
GLuint i;
{
GLuint i;
@@
-91,7
+91,7
@@
GLboolean vbo_all_varyings_in_vbos( const struct gl_client_array *arrays[] )
return GL_TRUE;
}
return GL_TRUE;
}
-GLboolean vbo_any_varyings_in_vbos( const struct gl_
client
_array *arrays[] )
+GLboolean vbo_any_varyings_in_vbos( const struct gl_
vertex
_array *arrays[] )
{
GLuint i;
{
GLuint i;
@@
-122,7
+122,7
@@
GLboolean vbo_any_varyings_in_vbos( const struct gl_client_array *arrays[] )
* all or nothing.
*/
void vbo_rebase_prims( struct gl_context *ctx,
* all or nothing.
*/
void vbo_rebase_prims( struct gl_context *ctx,
- const struct gl_
client
_array *arrays[],
+ const struct gl_
vertex
_array *arrays[],
const struct _mesa_prim *prim,
GLuint nr_prims,
const struct _mesa_index_buffer *ib,
const struct _mesa_prim *prim,
GLuint nr_prims,
const struct _mesa_index_buffer *ib,
@@
-130,19
+130,19
@@
void vbo_rebase_prims( struct gl_context *ctx,
GLuint max_index,
vbo_draw_func draw )
{
GLuint max_index,
vbo_draw_func draw )
{
- struct gl_
client
_array tmp_arrays[VERT_ATTRIB_MAX];
- const struct gl_
client
_array *tmp_array_pointers[VERT_ATTRIB_MAX];
+ struct gl_
vertex
_array tmp_arrays[VERT_ATTRIB_MAX];
+ const struct gl_
vertex
_array *tmp_array_pointers[VERT_ATTRIB_MAX];
struct _mesa_index_buffer tmp_ib;
struct _mesa_prim *tmp_prims = NULL;
struct _mesa_index_buffer tmp_ib;
struct _mesa_prim *tmp_prims = NULL;
- const struct gl_
client
_array **saved_arrays = ctx->Array._DrawArrays;
+ const struct gl_
vertex
_array **saved_arrays = ctx->Array._DrawArrays;
void *tmp_indices = NULL;
GLuint i;
assert(min_index != 0);
if (0)
void *tmp_indices = NULL;
GLuint i;
assert(min_index != 0);
if (0)
- printf("%s %d..%d\n", __
FUNCTION
__, min_index, max_index);
+ printf("%s %d..%d\n", __
func
__, min_index, max_index);
/* XXX this path is disabled for now.
/* XXX this path is disabled for now.
@@
-182,14
+182,14
@@
void vbo_rebase_prims( struct gl_context *ctx,
/* Some users might prefer it if we translated elements to
* GLuints here. Others wouldn't...
*/
/* Some users might prefer it if we translated elements to
* GLuints here. Others wouldn't...
*/
- switch (ib->
typ
e) {
- case
GL_UNSIGNED_INT:
+ switch (ib->
index_siz
e) {
+ case
4:
tmp_indices = rebase_GLuint( ptr, ib->count, min_index );
break;
tmp_indices = rebase_GLuint( ptr, ib->count, min_index );
break;
- case
GL_UNSIGNED_SHORT:
+ case
2:
tmp_indices = rebase_GLushort( ptr, ib->count, min_index );
break;
tmp_indices = rebase_GLushort( ptr, ib->count, min_index );
break;
- case
GL_UNSIGNED_BYTE:
+ case
1:
tmp_indices = rebase_GLubyte( ptr, ib->count, min_index );
break;
}
tmp_indices = rebase_GLubyte( ptr, ib->count, min_index );
break;
}
@@
-204,7
+204,7
@@
void vbo_rebase_prims( struct gl_context *ctx,
tmp_ib.obj = ctx->Shared->NullBufferObj;
tmp_ib.ptr = tmp_indices;
tmp_ib.count = ib->count;
tmp_ib.obj = ctx->Shared->NullBufferObj;
tmp_ib.ptr = tmp_indices;
tmp_ib.count = ib->count;
- tmp_ib.
type = ib->typ
e;
+ tmp_ib.
index_size = ib->index_siz
e;
ib = &tmp_ib;
}
ib = &tmp_ib;
}
@@
-258,7
+258,7
@@
void vbo_rebase_prims( struct gl_context *ctx,
GL_TRUE,
0,
max_index - min_index,
GL_TRUE,
0,
max_index - min_index,
- NULL, NULL );
+ NULL,
0,
NULL );
ctx->Array._DrawArrays = saved_arrays;
ctx->NewDriverState |= ctx->DriverFlags.NewArray;
ctx->Array._DrawArrays = saved_arrays;
ctx->NewDriverState |= ctx->DriverFlags.NewArray;