aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers/dri/i810/i810_3d_reg.h
diff options
context:
space:
mode:
authorIan Romanick <[email protected]>2005-08-29 15:43:02 +0000
committerIan Romanick <[email protected]>2005-08-29 15:43:02 +0000
commitf0d0e5099417796b629ad76e4e2fc19baa31c38d (patch)
tree8b097dec9c66c1e783def8dd398bc06fa783f9fc /src/mesa/drivers/dri/i810/i810_3d_reg.h
parentd9089ab96ecfbc9fbd8f6c772b08d2217dbeacaf (diff)
Implement GL_ARB_texture_env_combine, GL_EXT_texture_env_combine, and
GL_ARB_texture_env_crossbar for i810. This passes both demos/texenv and all of glean's texCombine tests.
Diffstat (limited to 'src/mesa/drivers/dri/i810/i810_3d_reg.h')
-rw-r--r--src/mesa/drivers/dri/i810/i810_3d_reg.h151
1 files changed, 73 insertions, 78 deletions
diff --git a/src/mesa/drivers/dri/i810/i810_3d_reg.h b/src/mesa/drivers/dri/i810/i810_3d_reg.h
index dade1a826c7..7cc59d5c86a 100644
--- a/src/mesa/drivers/dri/i810/i810_3d_reg.h
+++ b/src/mesa/drivers/dri/i810/i810_3d_reg.h
@@ -254,30 +254,30 @@
/* GFXRENDERSTATE_MAP_ALPHA_BLEND_STAGES, p132
*/
-#define GFX_OP_MAP_ALPHA_STAGES ((0x3<<29)|(0x1<<24))
-#define MA_STAGE_SHIFT 20
-#define MA_STAGE_0 (0<<20)
-#define MA_STAGE_1 (1<<20)
-#define MA_STAGE_2 (2<<20)
-#define MA_UPDATE_ARG1 (1<<18)
-#define MA_ARG1_MASK ((0x7<<15)|(0x1<<13))
-#define MA_ARG1_ALPHA_FACTOR (0x1<<15)
-#define MA_ARG1_ITERATED_ALPHA (0x3<<15)
-#define MA_ARG1_CURRENT_ALPHA (0x5<<15)
-#define MA_ARG1_TEX0_ALPHA (0x6<<15)
-#define MA_ARG1_TEX1_ALPHA (0x7<<15)
-#define MA_ARG1_INVERT (0x1<<13)
-#define MA_ARG1_DONT_INVERT (0x0<<13)
-#define MA_UPDATE_ARG2 (1<<12)
-#define MA_ARG2_MASK ((0x7<<8)|(0x1<<6))
-#define MA_ARG2_ALPHA_FACTOR (0x1<<8)
-#define MA_ARG2_ITERATED_ALPHA (0x3<<8)
-#define MA_ARG2_CURRENT_ALPHA (0x5<<8)
-#define MA_ARG2_TEX0_ALPHA (0x6<<8)
-#define MA_ARG2_TEX1_ALPHA (0x7<<8)
-#define MA_ARG2_INVERT (0x1<<6)
-#define MA_ARG2_DONT_INVERT (0x0<<6)
-#define MA_UPDATE_OP (1<<5)
+#define GFX_OP_MAP_ALPHA_STAGES ((0x3<<29)|(0x1<<24))
+#define MA_STAGE_SHIFT 20
+#define MA_STAGE_0 (0<<20)
+#define MA_STAGE_1 (1<<20)
+#define MA_STAGE_2 (2<<20)
+
+#define MA_ARG_ONE (0x0<<2)
+#define MA_ARG_ALPHA_FACTOR (0x1<<2)
+#define MA_ARG_ITERATED_ALPHA (0x3<<2)
+#define MA_ARG_CURRENT_ALPHA (0x5<<2)
+#define MA_ARG_TEX0_ALPHA (0x6<<2)
+#define MA_ARG_TEX1_ALPHA (0x7<<2)
+#define MA_ARG_INVERT (0x1)
+#define MA_ARG_DONT_INVERT (0x0)
+
+#define MA_UPDATE_ARG1 (1<<18)
+#define MA_ARG1_SHIFT 13
+#define MA_ARG1_MASK (0x1d << MA_ARG1_SHIFT)
+
+#define MA_UPDATE_ARG2 (1<<12)
+#define MA_ARG2_SHIFT 6
+#define MA_ARG2_MASK (0x1d << MA_ARG2_SHIFT)
+
+#define MA_UPDATE_OP (1<<5)
#define MA_OP_MASK (0xf)
#define MA_OP_ARG1 (0x1)
#define MA_OP_ARG2 (0x2)
@@ -290,64 +290,59 @@
#define MA_OP_LIN_BLEND_ALPHA_FACTOR (0xa)
#define MA_OP_LIN_BLEND_TEX0_ALPHA (0x10)
#define MA_OP_LIN_BLEND_TEX1_ALPHA (0x11)
+#define MA_OP_SUBTRACT (0x14)
/* GFXRENDERSTATE_MAP_COLOR_BLEND_STAGES, p129
*/
-#define GFX_OP_MAP_COLOR_STAGES ((0x3<<29)|(0x0<<24))
-#define MC_STAGE_SHIFT 20
-#define MC_STAGE_0 (0<<20)
-#define MC_STAGE_1 (1<<20)
-#define MC_STAGE_2 (2<<20)
-#define MC_UPDATE_DEST (1<<19)
-#define MC_DEST_MASK (1<<18)
-#define MC_DEST_CURRENT (0<<18)
-#define MC_DEST_ACCUMULATOR (1<<18)
-#define MC_UPDATE_ARG1 (1<<17)
-#define MC_ARG1_MASK ((0x7<<14)|(0x1<<13)|(0x1<<12))
-#define MC_ARG1_ONE (0x0<<14)
-#define MC_ARG1_COLOR_FACTOR (0x1<<14)
-#define MC_ARG1_ACCUMULATOR (0x2<<14)
-#define MC_ARG1_ITERATED_COLOR (0x3<<14)
-#define MC_ARG1_SPECULAR_COLOR (0x4<<14)
-#define MC_ARG1_CURRENT_COLOR (0x5<<14)
-#define MC_ARG1_TEX0_COLOR (0x6<<14)
-#define MC_ARG1_TEX1_COLOR (0x7<<14)
-#define MC_ARG1_DONT_REPLICATE_ALPHA (0x0<<13)
-#define MC_ARG1_REPLICATE_ALPHA (0x1<<13)
-#define MC_ARG1_DONT_INVERT (0x0<<12)
-#define MC_ARG1_INVERT (0x1<<12)
-#define MC_UPDATE_ARG2 (1<<11)
-#define MC_ARG2_MASK ((0x7<<8)|(0x1<<7)|(0x1<<6))
-#define MC_ARG2_ONE (0x0<<8)
-#define MC_ARG2_COLOR_FACTOR (0x1<<8)
-#define MC_ARG2_ACCUMULATOR (0x2<<8)
-#define MC_ARG2_ITERATED_COLOR (0x3<<8)
-#define MC_ARG2_SPECULAR_COLOR (0x4<<8)
-#define MC_ARG2_CURRENT_COLOR (0x5<<8)
-#define MC_ARG2_TEX0_COLOR (0x6<<8)
-#define MC_ARG2_TEX1_COLOR (0x7<<8)
-#define MC_ARG2_DONT_REPLICATE_ALPHA (0x0<<7)
-#define MC_ARG2_REPLICATE_ALPHA (0x1<<7)
-#define MC_ARG2_DONT_INVERT (0x0<<6)
-#define MC_ARG2_INVERT (0x1<<6)
-#define MC_UPDATE_OP (1<<5)
-#define MC_OP_MASK (0xf)
-#define MC_OP_DISABLE (0x0)
-#define MC_OP_ARG1 (0x1)
-#define MC_OP_ARG2 (0x2)
-#define MC_OP_MODULATE (0x3)
-#define MC_OP_MODULATE_X2 (0x4)
-#define MC_OP_MODULATE_X4 (0x5)
-#define MC_OP_ADD (0x6)
-#define MC_OP_ADD_SIGNED (0x7)
-#define MC_OP_LIN_BLEND_ITER_ALPHA (0x8)
-#define MC_OP_LIN_BLEND_ALPHA_FACTOR (0xa)
-#define MC_OP_LIN_BLEND_TEX0_ALPHA (0x10)
-#define MC_OP_LIN_BLEND_TEX1_ALPHA (0x11)
-#define MC_OP_LIN_BLEND_TEX0_COLOR (0x12)
-#define MC_OP_LIN_BLEND_TEX1_COLOR (0x13)
-#define MC_OP_SUBTRACT (0x14)
+#define GFX_OP_MAP_COLOR_STAGES ((0x3<<29)|(0x0<<24))
+#define MC_STAGE_SHIFT 20
+#define MC_STAGE_0 (0<<20)
+#define MC_STAGE_1 (1<<20)
+#define MC_STAGE_2 (2<<20)
+#define MC_UPDATE_DEST (1<<19)
+#define MC_DEST_MASK (1<<18)
+#define MC_DEST_CURRENT (0<<18)
+#define MC_DEST_ACCUMULATOR (1<<18)
+
+#define MC_ARG_ONE (0x0<<2)
+#define MC_ARG_COLOR_FACTOR (0x1<<2)
+#define MC_ARG_ACCUMULATOR (0x2<<2)
+#define MC_ARG_ITERATED_COLOR (0x3<<2)
+#define MC_ARG_SPECULAR_COLOR (0x4<<2)
+#define MC_ARG_CURRENT_COLOR (0x5<<2)
+#define MC_ARG_TEX0_COLOR (0x6<<2)
+#define MC_ARG_TEX1_COLOR (0x7<<2)
+#define MC_ARG_DONT_REPLICATE_ALPHA (0x0<<1)
+#define MC_ARG_REPLICATE_ALPHA (0x1<<1)
+#define MC_ARG_DONT_INVERT (0x0)
+#define MC_ARG_INVERT (0x1)
+
+#define MC_UPDATE_ARG1 (1<<17)
+#define MC_ARG1_SHIFT 12
+#define MC_ARG1_MASK (0x1f << MC_ARG1_SHIFT)
+
+#define MC_UPDATE_ARG2 (1<<11)
+#define MC_ARG2_SHIFT 6
+#define MC_ARG2_MASK (0x1f << MC_ARG2_SHIFT)
+
+#define MC_UPDATE_OP (1<<5)
+#define MC_OP_MASK (0xf)
+#define MC_OP_DISABLE (0x0)
+#define MC_OP_ARG1 (0x1)
+#define MC_OP_ARG2 (0x2)
+#define MC_OP_MODULATE (0x3)
+#define MC_OP_MODULATE_X2 (0x4)
+#define MC_OP_MODULATE_X4 (0x5)
+#define MC_OP_ADD (0x6)
+#define MC_OP_ADD_SIGNED (0x7)
+#define MC_OP_LIN_BLEND_ITER_ALPHA (0x8)
+#define MC_OP_LIN_BLEND_ALPHA_FACTOR (0xa)
+#define MC_OP_LIN_BLEND_TEX0_ALPHA (0x10)
+#define MC_OP_LIN_BLEND_TEX1_ALPHA (0x11)
+#define MC_OP_LIN_BLEND_TEX0_COLOR (0x12)
+#define MC_OP_LIN_BLEND_TEX1_COLOR (0x13)
+#define MC_OP_SUBTRACT (0x14)
/* GFXRENDERSTATE_MAP_PALETTE_LOAD, p128
*