From 2c9f50dd4acc65ddfeb8e3fde98137711167e579 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Tue, 25 Nov 2003 16:21:51 +0000 Subject: casts for g++ --- src/mesa/main/api_validate.c | 2 +- src/mesa/main/dlist.c | 2 +- src/mesa/main/image.c | 2 +- src/mesa/main/rastpos.c | 4 ++-- 4 files changed, 5 insertions(+), 5 deletions(-) (limited to 'src') diff --git a/src/mesa/main/api_validate.c b/src/mesa/main/api_validate.c index f6193aec55..53783b10e1 100644 --- a/src/mesa/main/api_validate.c +++ b/src/mesa/main/api_validate.c @@ -195,7 +195,7 @@ _mesa_validate_DrawArrays(GLcontext *ctx, return GL_FALSE; if (ctx->Const.CheckArrayBounds) { - if (start + count > ctx->Array._MaxElement) + if (start + count > (GLint) ctx->Array._MaxElement) return GL_FALSE; } diff --git a/src/mesa/main/dlist.c b/src/mesa/main/dlist.c index c547a2c74d..d8ef3bbb31 100644 --- a/src/mesa/main/dlist.c +++ b/src/mesa/main/dlist.c @@ -4753,7 +4753,7 @@ static void save_Indexf( GLfloat x ) ctx->ListState.CurrentIndex = x; if (ctx->ExecuteFlag) { - (*ctx->Exec->Indexi)( x ); + (*ctx->Exec->Indexi)( (GLint) x ); } } diff --git a/src/mesa/main/image.c b/src/mesa/main/image.c index 955f14f6b1..648ad8fe34 100644 --- a/src/mesa/main/image.c +++ b/src/mesa/main/image.c @@ -3809,7 +3809,7 @@ _mesa_pack_stencil_span( const GLcontext *ctx, GLuint n, GLhalfNV *dst = (GLhalfNV *) dest; GLuint i; for (i=0;iSwapBytes) { _mesa_swap2( (GLushort *) dst, n ); diff --git a/src/mesa/main/rastpos.c b/src/mesa/main/rastpos.c index dfd404e400..fac7dbd070 100644 --- a/src/mesa/main/rastpos.c +++ b/src/mesa/main/rastpos.c @@ -345,7 +345,7 @@ raster_pos4f(GLcontext *ctx, GLfloat x, GLfloat y, GLfloat z, GLfloat w) ctx->Current.Attrib[VERT_ATTRIB_COLOR1]); } else { - ctx->Current.RasterIndex = ctx->Current.Index; + ctx->Current.RasterIndex = (GLuint) ctx->Current.Index; } } @@ -636,7 +636,7 @@ window_pos3f(GLfloat x, GLfloat y, GLfloat z) = CLAMP(ctx->Current.Attrib[VERT_ATTRIB_COLOR1][3], 0.0F, 1.0F); } else { - ctx->Current.RasterIndex = ctx->Current.Index; + ctx->Current.RasterIndex = (GLuint) ctx->Current.Index; } /* raster texcoord = current texcoord */ -- cgit v1.2.3