summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2002-04-19 00:45:50 +0000
committerBrian Paul <[email protected]>2002-04-19 00:45:50 +0000
commit7322cccfb9a6b640743ca8cb527f7af922260cb8 (patch)
tree26d9274a94f5f5acd17758a69dc718eeea23ae68 /src
parent6c5b7029b3b805ecfae310a6e5fef15a5609a521 (diff)
new casts
Diffstat (limited to 'src')
-rw-r--r--src/mesa/tnl/t_array_api.c4
-rw-r--r--src/mesa/tnl/t_array_import.c8
-rw-r--r--src/mesa/tnl/t_imm_dlist.c6
3 files changed, 10 insertions, 8 deletions
diff --git a/src/mesa/tnl/t_array_api.c b/src/mesa/tnl/t_array_api.c
index 0ad9ca419b3..9be6c947937 100644
--- a/src/mesa/tnl/t_array_api.c
+++ b/src/mesa/tnl/t_array_api.c
@@ -1,4 +1,4 @@
-/* $Id: t_array_api.c,v 1.25 2002/04/09 16:56:50 keithw Exp $ */
+/* $Id: t_array_api.c,v 1.26 2002/04/19 00:45:50 brianp Exp $ */
/*
* Mesa 3-D graphics library
@@ -129,7 +129,7 @@ _tnl_DrawArrays(GLenum mode, GLint start, GLsizei count)
if (ctx->CompileFlag) {
fallback_drawarrays( ctx, mode, start, start + count );
}
- else if (!ctx->Array.LockCount && count < thresh) {
+ else if (!ctx->Array.LockCount && (GLuint) count < thresh) {
/* Small primitives: attempt to share a vb (at the expense of
* using the immediate interface).
*/
diff --git a/src/mesa/tnl/t_array_import.c b/src/mesa/tnl/t_array_import.c
index cec1b63239d..50ef1c86e30 100644
--- a/src/mesa/tnl/t_array_import.c
+++ b/src/mesa/tnl/t_array_import.c
@@ -1,4 +1,4 @@
-/* $Id: t_array_import.c,v 1.22 2002/01/22 14:35:16 brianp Exp $ */
+/* $Id: t_array_import.c,v 1.23 2002/04/19 00:45:50 brianp Exp $ */
/*
* Mesa 3-D graphics library
@@ -81,7 +81,7 @@ static void _tnl_import_normal( GLcontext *ctx,
stride ? 3*sizeof(GLfloat) : 0, writeable,
&is_writeable);
- inputs->Normal.data = tmp->Ptr;
+ inputs->Normal.data = (GLfloat (*)[4]) tmp->Ptr;
inputs->Normal.start = (GLfloat *) tmp->Ptr;
inputs->Normal.stride = tmp->StrideB;
inputs->Normal.flags &= ~(VEC_BAD_STRIDE|VEC_NOT_WRITEABLE);
@@ -394,11 +394,13 @@ void _tnl_vb_bind_arrays( GLcontext *ctx, GLint start, GLsizei count )
if (ctx->VertexProgram.Enabled) {
/* XXX lots of work to do here */
- printf("bind vp arrays!\n");
VB->AttribPtr[VERT_ATTRIB_POS] = VB->ObjPtr;
+ /*
+ printf("bind vp arrays!\n");
printf(" data = %p\n", VB->ObjPtr->data);
printf(" stride = %d\n", VB->ObjPtr->stride);
printf(" size = %d\n", VB->ObjPtr->size);
+ */
VB->AttribPtr[VERT_ATTRIB_NORMAL] = VB->NormalPtr;
}
diff --git a/src/mesa/tnl/t_imm_dlist.c b/src/mesa/tnl/t_imm_dlist.c
index 8805c23b12f..94da392804f 100644
--- a/src/mesa/tnl/t_imm_dlist.c
+++ b/src/mesa/tnl/t_imm_dlist.c
@@ -1,4 +1,4 @@
-/* $Id: t_imm_dlist.c,v 1.39 2002/04/09 16:56:52 keithw Exp $ */
+/* $Id: t_imm_dlist.c,v 1.40 2002/04/19 00:45:50 brianp Exp $ */
/*
* Mesa 3-D graphics library
@@ -76,7 +76,7 @@ static void build_normal_lengths( struct immediate *IM )
GLuint count = IM->Count - IM->Start;
if (!dest) {
- dest = IM->NormalLengthPtr = ALIGN_MALLOC( IMM_SIZE*sizeof(GLfloat), 32 );
+ dest = IM->NormalLengthPtr = (GLfloat *) ALIGN_MALLOC( IMM_SIZE*sizeof(GLfloat), 32 );
if (!dest) return;
}
dest += IM->Start;
@@ -391,7 +391,7 @@ destroy_compiled_cassette( GLcontext *ctx, void *data )
TNLvertexcassette *node = (TNLvertexcassette *)data;
if ( --node->IM->ref_count == 0 )
- _tnl_free_immediate( node->IM );
+ _tnl_free_immediate( ctx, node->IM );
}