summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbrianp <brianp>2002-11-14 23:51:18 +0000
committerbrianp <brianp>2002-11-14 23:51:18 +0000
commit82c3ccec33ee3d57e27d0b66315a40a6ebee37b1 (patch)
treebfbbd103bc418467f4b41ddc2cfdddb594dca035
parent14c0b954f2545cfe0c520824b0d7f456c94b45b3 (diff)
fix compiler warnings found with gcc 3.2
-rw-r--r--xc/lib/GL/mesa/src/drv/r200/r200_ioctl.c2
-rw-r--r--xc/lib/GL/mesa/src/drv/r200/r200_maos_arrays.c1
-rw-r--r--xc/lib/GL/mesa/src/drv/r200/r200_state.c2
-rw-r--r--xc/lib/GL/mesa/src/drv/r200/r200_state.h68
-rw-r--r--xc/lib/GL/mesa/src/drv/r200/r200_tex.c10
-rw-r--r--xc/lib/GL/mesa/src/drv/r200/r200_texmem.c6
-rw-r--r--xc/lib/GL/mesa/src/drv/r200/r200_texstate.c2
7 files changed, 80 insertions, 11 deletions
diff --git a/xc/lib/GL/mesa/src/drv/r200/r200_ioctl.c b/xc/lib/GL/mesa/src/drv/r200/r200_ioctl.c
index 545132ffb..0f0d3b27b 100644
--- a/xc/lib/GL/mesa/src/drv/r200/r200_ioctl.c
+++ b/xc/lib/GL/mesa/src/drv/r200/r200_ioctl.c
@@ -143,7 +143,7 @@ void r200FlushCmdBuf( r200ContextPtr rmesa, const char *caller )
UNLOCK_HARDWARE( rmesa );
if (ret) {
- fprintf(stderr, "drmRadeonCmdBuffer: %d\n", ret);
+ fprintf(stderr, "drmRadeonCmdBuffer: %d (exiting)\n", ret);
exit(ret);
}
}
diff --git a/xc/lib/GL/mesa/src/drv/r200/r200_maos_arrays.c b/xc/lib/GL/mesa/src/drv/r200/r200_maos_arrays.c
index a428112b7..9372a1f82 100644
--- a/xc/lib/GL/mesa/src/drv/r200/r200_maos_arrays.c
+++ b/xc/lib/GL/mesa/src/drv/r200/r200_maos_arrays.c
@@ -331,6 +331,7 @@ void r200EmitArrays( GLcontext *ctx, GLuint inputs )
case 3: vfmt0 |= R200_VTX_Z0;
case 2:
default:
+ ;
}
component[nr++] = &rmesa->tcl.obj;
}
diff --git a/xc/lib/GL/mesa/src/drv/r200/r200_state.c b/xc/lib/GL/mesa/src/drv/r200/r200_state.c
index 825fc276b..583b10cbd 100644
--- a/xc/lib/GL/mesa/src/drv/r200/r200_state.c
+++ b/xc/lib/GL/mesa/src/drv/r200/r200_state.c
@@ -1622,7 +1622,7 @@ static void r200Enable( GLcontext *ctx, GLenum cap, GLboolean state )
GLuint p, flag;
if ( R200_DEBUG & DEBUG_STATE )
- fprintf( stderr, __FUNCTION__"( %s = %s )\n",
+ fprintf( stderr, "%s( %s = %s )\n", __FUNCTION__,
_mesa_lookup_enum_by_nr( cap ),
state ? "GL_TRUE" : "GL_FALSE" );
diff --git a/xc/lib/GL/mesa/src/drv/r200/r200_state.h b/xc/lib/GL/mesa/src/drv/r200/r200_state.h
new file mode 100644
index 000000000..4eefa1838
--- /dev/null
+++ b/xc/lib/GL/mesa/src/drv/r200/r200_state.h
@@ -0,0 +1,68 @@
+/* $XFree86$ */
+/*
+Copyright (C) The Weather Channel, Inc. 2002. All Rights Reserved.
+
+The Weather Channel (TM) funded Tungsten Graphics to develop the
+initial release of the Radeon 8500 driver under the XFree86 license.
+This notice must be preserved.
+
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of this software and associated documentation files (the
+"Software"), to deal in the Software without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to
+permit persons to whom the Software is furnished to do so, subject to
+the following conditions:
+
+The above copyright notice and this permission notice (including the
+next paragraph) shall be included in all copies or substantial
+portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+IN NO EVENT SHALL THE COPYRIGHT OWNER(S) AND/OR ITS SUPPLIERS BE
+LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+*/
+
+/*
+ * Authors:
+ * Keith Whitwell <keith@tungstengraphics.com>
+ */
+
+#ifndef __R200_STATE_H__
+#define __R200_STATE_H__
+
+#ifdef GLX_DIRECT_RENDERING
+
+#include "r200_context.h"
+
+extern void r200InitState( r200ContextPtr rmesa );
+extern void r200InitStateFuncs( GLcontext *ctx );
+
+extern void r200UpdateMaterial( GLcontext *ctx );
+
+extern void r200SetCliprects( r200ContextPtr rmesa, GLenum mode );
+extern void r200RecalcScissorRects( r200ContextPtr rmesa );
+extern void r200UpdateViewportOffset( GLcontext *ctx );
+extern void r200UpdateWindow( GLcontext *ctx );
+
+extern void r200ValidateState( GLcontext *ctx );
+
+extern void r200PrintDirty( r200ContextPtr rmesa,
+ const char *msg );
+
+
+extern void r200Fallback( GLcontext *ctx, GLuint bit, GLboolean mode );
+#define FALLBACK( rmesa, bit, mode ) do { \
+ if ( 0 ) fprintf( stderr, "FALLBACK in %s: #%d=%d\n", \
+ __FUNCTION__, bit, mode ); \
+ r200Fallback( rmesa->glCtx, bit, mode ); \
+} while (0)
+
+extern void r200LightingSpaceChange( GLcontext *ctx );
+
+#endif
+#endif
diff --git a/xc/lib/GL/mesa/src/drv/r200/r200_tex.c b/xc/lib/GL/mesa/src/drv/r200/r200_tex.c
index 78645e7be..0374047f3 100644
--- a/xc/lib/GL/mesa/src/drv/r200/r200_tex.c
+++ b/xc/lib/GL/mesa/src/drv/r200/r200_tex.c
@@ -234,7 +234,7 @@ static r200TexObjPtr r200AllocTexObj( struct gl_texture_object *texObj )
return NULL;
if ( R200_DEBUG & DEBUG_TEXTURE ) {
- fprintf( stderr, __FUNCTION__"( %p, %p )\n", texObj, t );
+ fprintf( stderr, "%s( %p, %p )\n", __FUNCTION__, texObj, t );
}
t->tObj = texObj;
@@ -800,8 +800,8 @@ static void r200TexParameter( GLcontext *ctx, GLenum target,
r200TexObjPtr t = (r200TexObjPtr) texObj->DriverData;
if ( R200_DEBUG & (DEBUG_STATE|DEBUG_TEXTURE) ) {
- fprintf( stderr, __FUNCTION__"( %s )\n",
- _mesa_lookup_enum_by_nr( pname ) );
+ fprintf( stderr, "%s( %s )\n", __FUNCTION__,
+ _mesa_lookup_enum_by_nr( pname ) );
}
if (!t)
@@ -855,7 +855,7 @@ static void r200BindTexture( GLcontext *ctx, GLenum target,
GLuint unit = ctx->Texture.CurrentUnit;
if ( R200_DEBUG & (DEBUG_STATE|DEBUG_TEXTURE) ) {
- fprintf( stderr, __FUNCTION__"( %p ) unit=%d\n", texObj, unit );
+ fprintf( stderr, "%s( %p ) unit=%d\n", __FUNCTION__, texObj, unit );
}
if ( target == GL_TEXTURE_2D || target == GL_TEXTURE_1D ) {
@@ -873,7 +873,7 @@ static void r200DeleteTexture( GLcontext *ctx,
r200TexObjPtr t = (r200TexObjPtr) texObj->DriverData;
if ( R200_DEBUG & (DEBUG_STATE|DEBUG_TEXTURE) ) {
- fprintf( stderr, __FUNCTION__"( %p )\n", texObj );
+ fprintf( stderr, "%s( %p )\n", __FUNCTION__, texObj );
}
if ( t ) {
diff --git a/xc/lib/GL/mesa/src/drv/r200/r200_texmem.c b/xc/lib/GL/mesa/src/drv/r200/r200_texmem.c
index a5cb5fd4f..5f91e3e8c 100644
--- a/xc/lib/GL/mesa/src/drv/r200/r200_texmem.c
+++ b/xc/lib/GL/mesa/src/drv/r200/r200_texmem.c
@@ -59,7 +59,7 @@ void r200DestroyTexObj( r200ContextPtr rmesa, r200TexObjPtr t )
return;
if ( R200_DEBUG & DEBUG_TEXTURE ) {
- fprintf( stderr, __FUNCTION__"( %p, %p )\n", t, t->tObj );
+ fprintf( stderr, "%s( %p, %p )\n", __FUNCTION__, t, t->tObj );
}
if ( t->memBlock ) {
@@ -100,7 +100,7 @@ void r200SwapOutTexObj( r200ContextPtr rmesa, r200TexObjPtr t )
GLuint face;
if ( R200_DEBUG & DEBUG_TEXTURE ) {
- fprintf( stderr, __FUNCTION__"( %p, %p )\n", t, t->tObj );
+ fprintf( stderr, "%s( %p, %p )\n", __FUNCTION__, t, t->tObj );
}
if ( t->memBlock ) {
@@ -703,7 +703,7 @@ int r200UploadTexImages( r200ContextPtr rmesa, r200TexObjPtr t, GLuint face )
r200TexObjPtr t1 = rmesa->state.texture.unit[1].texobj;
if ( R200_DEBUG & (DEBUG_TEXTURE|DEBUG_IOCTL) ) {
- fprintf( stderr, __FUNCTION__"( %p, %p ) sz=%d lvls=%d-%d\n",
+ fprintf( stderr, "%s( %p, %p ) sz=%d lvls=%d-%d\n", __FUNCTION__,
rmesa->glCtx, t->tObj, t->totalSize,
t->firstLevel, t->lastLevel );
}
diff --git a/xc/lib/GL/mesa/src/drv/r200/r200_texstate.c b/xc/lib/GL/mesa/src/drv/r200/r200_texstate.c
index 07c0465c0..5be304094 100644
--- a/xc/lib/GL/mesa/src/drv/r200/r200_texstate.c
+++ b/xc/lib/GL/mesa/src/drv/r200/r200_texstate.c
@@ -720,7 +720,7 @@ static void r200UpdateTextureEnv( GLcontext *ctx, int unit )
GLuint alpha_scale = rmesa->hw.pix[unit].cmd[PIX_PP_TXABLEND2];
if ( R200_DEBUG & DEBUG_TEXTURE ) {
- fprintf( stderr, __FUNCTION__"( %p, %d )\n", ctx, unit );
+ fprintf( stderr, "%s( %p, %d )\n", __FUNCTION__, ctx, unit );
}
/* Set the texture environment state. Isn't this nice and clean?