summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristopher Egert <[email protected]>2018-09-08 02:16:48 +0200
committerMarek Olšák <[email protected]>2018-09-10 16:57:20 -0400
commit51995f69204e8a751cb1a3e502e013acf7fff031 (patch)
tree989e7868434e6ce912f7bdb63372119320fc4f3a
parent9179c745f646a85274b7a295ee3577e48f8d0d3f (diff)
radeon: fix ColorMask
Since commit af3685d14936844f79e6f372b4b258e29375f21b various OpenGL applications regressed on the classic mesa radeon driver. Signed-off-by: Christopher Egert <[email protected]> CC: 18.1 18.2 <[email protected]> Signed-off-by: Marek Olšák <[email protected]>
-rw-r--r--src/mesa/drivers/dri/r200/r200_state.c8
-rw-r--r--src/mesa/drivers/dri/radeon/radeon_state.c8
2 files changed, 8 insertions, 8 deletions
diff --git a/src/mesa/drivers/dri/r200/r200_state.c b/src/mesa/drivers/dri/r200/r200_state.c
index d53225d63ab..b4cff8c2592 100644
--- a/src/mesa/drivers/dri/r200/r200_state.c
+++ b/src/mesa/drivers/dri/r200/r200_state.c
@@ -688,10 +688,10 @@ static void r200ColorMask( struct gl_context *ctx,
if (!rrb)
return;
mask = radeonPackColor( rrb->cpp,
- GET_COLORMASK_BIT(ctx->Color.ColorMask, 0, 0),
- GET_COLORMASK_BIT(ctx->Color.ColorMask, 0, 1),
- GET_COLORMASK_BIT(ctx->Color.ColorMask, 0, 2),
- GET_COLORMASK_BIT(ctx->Color.ColorMask, 0, 3) );
+ GET_COLORMASK_BIT(ctx->Color.ColorMask, 0, 0)*0xFF,
+ GET_COLORMASK_BIT(ctx->Color.ColorMask, 0, 1)*0xFF,
+ GET_COLORMASK_BIT(ctx->Color.ColorMask, 0, 2)*0xFF,
+ GET_COLORMASK_BIT(ctx->Color.ColorMask, 0, 3)*0xFF );
if (!(r && g && b && a))
diff --git a/src/mesa/drivers/dri/radeon/radeon_state.c b/src/mesa/drivers/dri/radeon/radeon_state.c
index 8b72c98a3b2..410a78fc084 100644
--- a/src/mesa/drivers/dri/radeon/radeon_state.c
+++ b/src/mesa/drivers/dri/radeon/radeon_state.c
@@ -503,10 +503,10 @@ static void radeonColorMask( struct gl_context *ctx,
return;
mask = radeonPackColor( rrb->cpp,
- GET_COLORMASK_BIT(ctx->Color.ColorMask, 0, 0),
- GET_COLORMASK_BIT(ctx->Color.ColorMask, 0, 1),
- GET_COLORMASK_BIT(ctx->Color.ColorMask, 0, 2),
- GET_COLORMASK_BIT(ctx->Color.ColorMask, 0, 3) );
+ GET_COLORMASK_BIT(ctx->Color.ColorMask, 0, 0)*0xFF,
+ GET_COLORMASK_BIT(ctx->Color.ColorMask, 0, 1)*0xFF,
+ GET_COLORMASK_BIT(ctx->Color.ColorMask, 0, 2)*0xFF,
+ GET_COLORMASK_BIT(ctx->Color.ColorMask, 0, 3)*0xFF );
if ( rmesa->hw.msk.cmd[MSK_RB3D_PLANEMASK] != mask ) {
RADEON_STATECHANGE( rmesa, msk );