Mesa (master): r300-gallium: Quick little cleanup of surface_fill state.
Corbin Simpson
csimpson at kemper.freedesktop.org
Tue Mar 17 20:14:26 UTC 2009
Module: Mesa
Branch: master
Commit: 9d5e6f66f004d7eaed905802eb761b2129f909c4
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=9d5e6f66f004d7eaed905802eb761b2129f909c4
Author: Corbin Simpson <MostAwesomeDude at gmail.com>
Date: Tue Mar 17 13:07:44 2009 -0700
r300-gallium: Quick little cleanup of surface_fill state.
---
src/gallium/drivers/r300/r300_surface.c | 23 +++++++++++------------
1 files changed, 11 insertions(+), 12 deletions(-)
diff --git a/src/gallium/drivers/r300/r300_surface.c b/src/gallium/drivers/r300/r300_surface.c
index 744d603..db7cc02 100644
--- a/src/gallium/drivers/r300/r300_surface.c
+++ b/src/gallium/drivers/r300/r300_surface.c
@@ -69,7 +69,7 @@ static void r300_surface_fill(struct pipe_context* pipe,
r300_emit_rs_block_state(r300, &r300_rs_block_clear_state);
}
- BEGIN_CS(97 + (caps->has_tcl ? 9 : 0));
+ BEGIN_CS(99 + (caps->has_tcl ? 28 : 0));
/* Flush PVS. */
OUT_CS_REG(R300_VAP_PVS_STATE_FLUSH_REG, 0x0);
@@ -152,20 +152,10 @@ static void r300_surface_fill(struct pipe_context* pipe,
OUT_CS_REG(R300_VAP_OUTPUT_VTX_FMT_0, 0x00000003);
OUT_CS_REG(R300_VAP_OUTPUT_VTX_FMT_1, 0x00000000);
OUT_CS_REG(R300_TX_ENABLE, 0x0);
- /* XXX viewport setup */
- OUT_CS_REG_SEQ(R300_SE_VPORT_XSCALE, 6);
- OUT_CS_32F(1.0);
- OUT_CS_32F((float)x);
- OUT_CS_32F(1.0);
- OUT_CS_32F((float)y);
- OUT_CS_32F(1.0);
- OUT_CS_32F(0.0);
/* XXX */
OUT_CS_REG(R300_SC_CLIP_RULE, 0xaaaa);
- END_CS;
- BEGIN_CS(7 + (caps->has_tcl ? 21 : 2));
OUT_CS_REG_SEQ(R300_US_OUT_FMT_0, 4);
OUT_CS(R300_C0_SEL_B | R300_C1_SEL_G | R300_C2_SEL_R | R300_C3_SEL_A);
OUT_CS(R300_US_OUT_FMT_UNUSED);
@@ -202,7 +192,16 @@ static void r300_surface_fill(struct pipe_context* pipe,
}
END_CS;
- BEGIN_CS(29);
+ BEGIN_CS(36);
+
+ /* Viewport setup */
+ OUT_CS_REG_SEQ(R300_SE_VPORT_XSCALE, 6);
+ OUT_CS_32F(1.0);
+ OUT_CS_32F((float)x);
+ OUT_CS_32F(1.0);
+ OUT_CS_32F((float)y);
+ OUT_CS_32F(1.0);
+ OUT_CS_32F(0.0);
/* Pixel scissors */
OUT_CS_REG_SEQ(R300_SC_SCISSORS_TL, 2);
More information about the mesa-commit
mailing list