From 8e01fd63965e0c7ab0854e0a899d6138deca5b07 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Mathias=20Fr=C3=B6hlich?= Date: Sun, 22 May 2016 14:10:19 +0200 Subject: [PATCH] r200: convert r200 to use CoordsReplaceBits. MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Switch over to use the CoordsReplaceBits bitmask. Reviewed-by: Brian Paul Reviewed-by: Ian Romanick Signed-off-by: Mathias Fröhlich --- src/mesa/drivers/dri/r200/r200_state.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/mesa/drivers/dri/r200/r200_state.c b/src/mesa/drivers/dri/r200/r200_state.c index b4acf985ee8..e2a56d5e07b 100644 --- a/src/mesa/drivers/dri/r200/r200_state.c +++ b/src/mesa/drivers/dri/r200/r200_state.c @@ -1851,11 +1851,8 @@ static void r200Enable( struct gl_context *ctx, GLenum cap, GLboolean state ) case GL_POINT_SPRITE_ARB: R200_STATECHANGE( rmesa, spr ); if ( state ) { - int i; - for (i = 0; i < 6; i++) { - rmesa->hw.spr.cmd[SPR_POINT_SPRITE_CNTL] |= - ctx->Point.CoordReplace[i] << (R200_PS_GEN_TEX_0_SHIFT + i); - } + rmesa->hw.spr.cmd[SPR_POINT_SPRITE_CNTL] |= R200_PS_GEN_TEX_MASK & + (ctx->Point.CoordReplaceBits << R200_PS_GEN_TEX_0_SHIFT); } else { rmesa->hw.spr.cmd[SPR_POINT_SPRITE_CNTL] &= ~R200_PS_GEN_TEX_MASK; } -- 2.30.2