summaryrefslogtreecommitdiff
path: root/src/gallium/drivers/r600/r600_state.c
diff options
context:
space:
mode:
authorHenri Verbeet <hverbeet@gmail.com>2011-03-14 22:07:44 +0100
committerHenri Verbeet <hverbeet@gmail.com>2011-03-14 22:15:56 +0100
commita2ef38368b638caba26418a68c157d52b6bcf797 (patch)
tree30f0c85cbb5dc92921c3ac99a577ee15090c92f6 /src/gallium/drivers/r600/r600_state.c
parentf262ba26f045699f0aa871b6be966714e9dd6740 (diff)
r600g: Move fetch shader register setup to r600_state.c / evergreen_state.c.
Signed-off-by: Henri Verbeet <hverbeet@gmail.com>
Diffstat (limited to 'src/gallium/drivers/r600/r600_state.c')
-rw-r--r--src/gallium/drivers/r600/r600_state.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/gallium/drivers/r600/r600_state.c b/src/gallium/drivers/r600/r600_state.c
index 170f96be93..f1e21bcead 100644
--- a/src/gallium/drivers/r600/r600_state.c
+++ b/src/gallium/drivers/r600/r600_state.c
@@ -1366,6 +1366,22 @@ void r600_pipe_shader_vs(struct pipe_context *ctx, struct r600_pipe_shader *shad
0xFFFFFFFF, NULL);
}
+void r600_fetch_shader(struct r600_vertex_element *ve)
+{
+ struct r600_pipe_state *rstate;
+
+ rstate = &ve->rstate;
+ rstate->id = R600_PIPE_STATE_FETCH_SHADER;
+ rstate->nregs = 0;
+ r600_pipe_state_add_reg(rstate, R_0288A4_SQ_PGM_RESOURCES_FS,
+ 0x00000000, 0xFFFFFFFF, NULL);
+ r600_pipe_state_add_reg(rstate, R_0288DC_SQ_PGM_CF_OFFSET_FS,
+ 0x00000000, 0xFFFFFFFF, NULL);
+ r600_pipe_state_add_reg(rstate, R_028894_SQ_PGM_START_FS,
+ r600_bo_offset(ve->fetch_shader) >> 8,
+ 0xFFFFFFFF, ve->fetch_shader);
+}
+
void *r600_create_db_flush_dsa(struct r600_pipe_context *rctx)
{
struct pipe_depth_stencil_alpha_state dsa;