Hi,
here is a simple cleanup patch for r300 dri driver. It's pretty trivial so I
think it can be commited without a problem.
Maciej Cencora
From 61a56a046e215075745adad49e784800fad48180 Mon Sep 17 00:00:00 2001
From: Maciej Cencora <m.cenc...@gmail.com>
Date: Thu, 19 Mar 2009 21:17:01 +0100
Subject: [PATCH] r300: cleanup swtcl a little
- remove disabled code
- silence compiler warnings (uinitialized values)
- remove unneeded code
---
src/mesa/drivers/dri/r300/r300_swtcl.c | 10 +---------
1 files changed, 1 insertions(+), 9 deletions(-)
diff --git a/src/mesa/drivers/dri/r300/r300_swtcl.c b/src/mesa/drivers/dri/r300/r300_swtcl.c
index d463ab3..ba3621b 100644
--- a/src/mesa/drivers/dri/r300/r300_swtcl.c
+++ b/src/mesa/drivers/dri/r300/r300_swtcl.c
@@ -504,7 +504,7 @@ do { \
#define LOCAL_VARS(n) \
r300ContextPtr rmesa = R300_CONTEXT(ctx); \
- GLuint color[n], spec[n]; \
+ GLuint color[n] = { 0, }, spec[n] = { 0, }; \
GLuint coloroffset = rmesa->swtcl.coloroffset; \
GLuint specoffset = rmesa->swtcl.specoffset; \
(void) color; (void) spec; (void) coloroffset; (void) specoffset;
@@ -629,7 +629,6 @@ static void r300ChooseRenderState( GLcontext *ctx )
static void r300RenderStart(GLcontext *ctx)
{
r300ContextPtr rmesa = R300_CONTEXT( ctx );
- // fprintf(stderr, "%s\n", __FUNCTION__);
r300ChooseRenderState(ctx);
r300SetVertexFormat(ctx);
@@ -669,8 +668,6 @@ static void r300RenderPrimitive(GLcontext *ctx, GLenum prim)
return;
r300RasterPrimitive( ctx, reduced_prim[prim] );
- // fprintf(stderr, "%s\n", __FUNCTION__);
-
}
static void r300ResetLineStipple(GLcontext *ctx)
@@ -713,11 +710,6 @@ void r300InitSwtcl(GLcontext *ctx)
_tnl_need_projected_coords( ctx, GL_FALSE );
r300ChooseRenderState(ctx);
-
- _mesa_validate_all_lighting_tables( ctx );
-
- tnl->Driver.NotifyMaterialChange =
- _mesa_validate_all_lighting_tables;
}
void r300DestroySwtcl(GLcontext *ctx)
--
1.5.6.3
------------------------------------------------------------------------------
Apps built with the Adobe(R) Flex(R) framework and Flex Builder(TM) are
powering Web 2.0 with engaging, cross-platform capabilities. Quickly and
easily build your RIAs with Flex Builder, the Eclipse(TM)based development
software that enables intelligent coding and step-through debugging.
Download the free 60 day trial. http://p.sf.net/sfu/www-adobe-com
_______________________________________________
Mesa3d-dev mailing list
Mesa3d-dev@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mesa3d-dev