summaryrefslogtreecommitdiff
path: root/src/gallium/drivers/r600/r600_context.h
diff options
context:
space:
mode:
authorDave Airlie <airlied@redhat.com>2010-09-16 09:33:34 +1000
committerDave Airlie <airlied@redhat.com>2010-09-16 09:40:42 +1000
commit05433f20b6547e105d172bd586d3b6ce1b9d0f97 (patch)
tree548840c6141b94f5c8e0961f6d82cceb5135a404 /src/gallium/drivers/r600/r600_context.h
parent0a7824862eb753878fa79b153b2a111884ff1197 (diff)
r600g: pull r600_draw struct out into header
we need this for future buffer rework, it also makes the vtbl easier
Diffstat (limited to 'src/gallium/drivers/r600/r600_context.h')
-rw-r--r--src/gallium/drivers/r600/r600_context.h20
1 files changed, 15 insertions, 5 deletions
diff --git a/src/gallium/drivers/r600/r600_context.h b/src/gallium/drivers/r600/r600_context.h
index 58f6d0232b..7366810de2 100644
--- a/src/gallium/drivers/r600/r600_context.h
+++ b/src/gallium/drivers/r600/r600_context.h
@@ -114,6 +114,17 @@ struct r600_vertex_element
struct pipe_vertex_element elements[32];
};
+struct r600_draw {
+ struct pipe_context *ctx;
+ struct radeon_state draw;
+ struct radeon_state vgt;
+ unsigned mode;
+ unsigned start;
+ unsigned count;
+ unsigned index_size;
+ struct pipe_resource *index_buffer;
+};
+
struct r600_context_hw_states {
struct radeon_state rasterizer;
struct radeon_state scissor;
@@ -162,11 +173,10 @@ struct r600_context_hw_state_vtbl {
void (*cb_cntl)(struct r600_context *rctx, struct radeon_state *rstate);
int (*vs_resource)(struct r600_context *rctx, int id, struct r600_resource *rbuffer, uint32_t offset,
uint32_t stride, uint32_t format);
- int (*vgt_init)(struct r600_context *rctx, struct radeon_state *draw,
- struct r600_resource *rbuffer,
- uint32_t count, int vgt_draw_initiator);
- int (*vgt_prim)(struct r600_context *rctx, struct radeon_state *vgt,
- uint32_t prim, uint32_t start, uint32_t vgt_dma_index_type);
+ int (*vgt_init)(struct r600_draw *draw,
+ int vgt_draw_initiator);
+ int (*vgt_prim)(struct r600_draw *draw,
+ uint32_t prim, uint32_t vgt_dma_index_type);
int (*ps_shader)(struct r600_context *rctx, struct r600_context_state *rshader,
struct radeon_state *state);