summaryrefslogtreecommitdiff
path: root/src/mesa
diff options
context:
space:
mode:
authorEric Anholt <anholt@FreeBSD.org>2005-10-28 06:15:11 +0000
committerEric Anholt <anholt@FreeBSD.org>2005-10-28 06:15:11 +0000
commitc57be49099428d6868b9f9215c6b2af9bcfd5a41 (patch)
treedc3f28e5ccacf412da77d389278d50ecd40dd980 /src/mesa
parent4b9f1308e55003308a744ad15eed6cab676e4785 (diff)
Correct the ordering of the blend constant color.
Diffstat (limited to 'src/mesa')
-rw-r--r--src/mesa/drivers/dri/r300/r300_context.h2
-rw-r--r--src/mesa/drivers/dri/r300/r300_state.c5
2 files changed, 4 insertions, 3 deletions
diff --git a/src/mesa/drivers/dri/r300/r300_context.h b/src/mesa/drivers/dri/r300/r300_context.h
index cb2e4bb321..96f4ff6afa 100644
--- a/src/mesa/drivers/dri/r300/r300_context.h
+++ b/src/mesa/drivers/dri/r300/r300_context.h
@@ -454,7 +454,7 @@ struct r300_hw_state {
struct r300_state_atom unk4E00; /* (4E00) */
struct r300_state_atom bld; /* blending (4E04) */
struct r300_state_atom cmk; /* colormask (4E0C) */
- struct r300_state_atom unk4E10; /* (4E10) */
+ struct r300_state_atom unk4E10; /* constant blend color + ??? (4E10) */
struct r300_state_atom cb; /* colorbuffer (4E28) */
struct r300_state_atom unk4E50; /* (4E50) */
struct r300_state_atom unk4E88; /* (4E88) */
diff --git a/src/mesa/drivers/dri/r300/r300_state.c b/src/mesa/drivers/dri/r300/r300_state.c
index 90304a05fd..6ab7d97faf 100644
--- a/src/mesa/drivers/dri/r300/r300_state.c
+++ b/src/mesa/drivers/dri/r300/r300_state.c
@@ -118,13 +118,13 @@ static void r300BlendColor(GLcontext * ctx, const GLfloat cf[4])
R300_STATECHANGE(rmesa, unk4E10);
- /* Ordering might be wrong */
CLAMPED_FLOAT_TO_UBYTE(color[0], cf[0]);
CLAMPED_FLOAT_TO_UBYTE(color[1], cf[1]);
CLAMPED_FLOAT_TO_UBYTE(color[2], cf[2]);
CLAMPED_FLOAT_TO_UBYTE(color[3], cf[3]);
- rmesa->hw.unk4E10.cmd[1]=r300PackColor(4, color[0], color[1], color[2], color[3]);
+ rmesa->hw.unk4E10.cmd[1] = r300PackColor(4, color[3], color[0],
+ color[1], color[2]);
}
/**
@@ -194,6 +194,7 @@ static int blend_factor(GLenum factor, GLboolean is_src)
func = R200_BLEND_GL_ONE_MINUS_CONST_ALPHA;
break;
default:
+ fprintf(stderr, "unknown blend factor %x\n", factor);
func = (is_src) ? R200_BLEND_GL_ONE : R200_BLEND_GL_ZERO;
}
return func;