From 7c5f255201f42303188137f56ea8acc030444f0e Mon Sep 17 00:00:00 2001 From: Michal Krol Date: Mon, 25 Jan 2010 13:29:33 +0100 Subject: gallium: Rename PIPE_MAX_CONSTANT to PIPE_MAX_CONSTANT_BUFFERS. --- src/gallium/drivers/softpipe/sp_context.c | 2 +- src/gallium/drivers/softpipe/sp_context.h | 4 ++-- src/gallium/drivers/softpipe/sp_draw_arrays.c | 8 ++++---- src/gallium/drivers/softpipe/sp_quad_fs.c | 2 +- src/gallium/drivers/softpipe/sp_state_fs.c | 2 +- 5 files changed, 9 insertions(+), 9 deletions(-) (limited to 'src/gallium/drivers') diff --git a/src/gallium/drivers/softpipe/sp_context.c b/src/gallium/drivers/softpipe/sp_context.c index a3a7825aa1..53133d2888 100644 --- a/src/gallium/drivers/softpipe/sp_context.c +++ b/src/gallium/drivers/softpipe/sp_context.c @@ -114,7 +114,7 @@ softpipe_destroy( struct pipe_context *pipe ) for (i = 0; i < PIPE_SHADER_TYPES; i++) { uint j; - for (j = 0; j < PIPE_MAX_CONSTANT; j++) { + for (j = 0; j < PIPE_MAX_CONSTANT_BUFFERS; j++) { if (softpipe->constants[i][j]) { pipe_buffer_reference(&softpipe->constants[i][j], NULL); } diff --git a/src/gallium/drivers/softpipe/sp_context.h b/src/gallium/drivers/softpipe/sp_context.h index f19b3cd5be..be4613b622 100644 --- a/src/gallium/drivers/softpipe/sp_context.h +++ b/src/gallium/drivers/softpipe/sp_context.h @@ -63,7 +63,7 @@ struct softpipe_context { /** Other rendering state */ struct pipe_blend_color blend_color; struct pipe_clip_state clip; - struct pipe_buffer *constants[PIPE_SHADER_TYPES][PIPE_MAX_CONSTANT]; + struct pipe_buffer *constants[PIPE_SHADER_TYPES][PIPE_MAX_CONSTANT_BUFFERS]; struct pipe_framebuffer_state framebuffer; struct pipe_poly_stipple poly_stipple; struct pipe_scissor_state scissor; @@ -92,7 +92,7 @@ struct softpipe_context { ubyte *mapped_vbuffer[PIPE_MAX_ATTRIBS]; /** Mapped constant buffers */ - void *mapped_constants[PIPE_SHADER_TYPES][PIPE_MAX_CONSTANT]; + void *mapped_constants[PIPE_SHADER_TYPES][PIPE_MAX_CONSTANT_BUFFERS]; /** Vertex format */ struct vertex_info vertex_info; diff --git a/src/gallium/drivers/softpipe/sp_draw_arrays.c b/src/gallium/drivers/softpipe/sp_draw_arrays.c index 06b97ab7c9..2b82427d54 100644 --- a/src/gallium/drivers/softpipe/sp_draw_arrays.c +++ b/src/gallium/drivers/softpipe/sp_draw_arrays.c @@ -54,7 +54,7 @@ softpipe_map_constant_buffers(struct softpipe_context *sp) for (i = 0; i < PIPE_SHADER_TYPES; i++) { uint j; - for (j = 0; j < PIPE_MAX_CONSTANT; j++) { + for (j = 0; j < PIPE_MAX_CONSTANT_BUFFERS; j++) { if (sp->constants[i][j] && sp->constants[i][j]->size) { sp->mapped_constants[i][j] = ws->buffer_map(ws, sp->constants[i][j], @@ -63,7 +63,7 @@ softpipe_map_constant_buffers(struct softpipe_context *sp) } } - for (i = 0; i < PIPE_MAX_CONSTANT; i++) { + for (i = 0; i < PIPE_MAX_CONSTANT_BUFFERS; i++) { if (sp->constants[PIPE_SHADER_VERTEX][i]) { draw_set_mapped_constant_buffer(sp->draw, PIPE_SHADER_VERTEX, @@ -93,7 +93,7 @@ softpipe_unmap_constant_buffers(struct softpipe_context *sp) */ draw_flush(sp->draw); - for (i = 0; i < PIPE_MAX_CONSTANT; i++) { + for (i = 0; i < PIPE_MAX_CONSTANT_BUFFERS; i++) { draw_set_mapped_constant_buffer(sp->draw, PIPE_SHADER_VERTEX, i, @@ -109,7 +109,7 @@ softpipe_unmap_constant_buffers(struct softpipe_context *sp) for (i = 0; i < PIPE_SHADER_TYPES; i++) { uint j; - for (j = 0; j < PIPE_MAX_CONSTANT; j++) { + for (j = 0; j < PIPE_MAX_CONSTANT_BUFFERS; j++) { if (sp->constants[i][j] && sp->constants[i][j]->size) { ws->buffer_unmap(ws, sp->constants[i][j]); } diff --git a/src/gallium/drivers/softpipe/sp_quad_fs.c b/src/gallium/drivers/softpipe/sp_quad_fs.c index 9c497073c2..ad04dc2afc 100644 --- a/src/gallium/drivers/softpipe/sp_quad_fs.c +++ b/src/gallium/drivers/softpipe/sp_quad_fs.c @@ -109,7 +109,7 @@ shade_quads(struct quad_stage *qs, struct tgsi_exec_machine *machine = qss->machine; unsigned i, pass = 0; - for (i = 0; i < PIPE_MAX_CONSTANT; i++) { + for (i = 0; i < PIPE_MAX_CONSTANT_BUFFERS; i++) { machine->Consts[i] = softpipe->mapped_constants[PIPE_SHADER_FRAGMENT][i]; } machine->InterpCoefs = quads[0]->coef; diff --git a/src/gallium/drivers/softpipe/sp_state_fs.c b/src/gallium/drivers/softpipe/sp_state_fs.c index 50ed51661a..04bdcaacc2 100644 --- a/src/gallium/drivers/softpipe/sp_state_fs.c +++ b/src/gallium/drivers/softpipe/sp_state_fs.c @@ -164,7 +164,7 @@ softpipe_set_constant_buffer(struct pipe_context *pipe, struct softpipe_context *softpipe = softpipe_context(pipe); assert(shader < PIPE_SHADER_TYPES); - assert(index < PIPE_MAX_CONSTANT); + assert(index < PIPE_MAX_CONSTANT_BUFFERS); draw_flush(softpipe->draw); -- cgit v1.2.3