summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/cell
diff options
context:
space:
mode:
authorJosé Fonseca <[email protected]>2010-04-19 18:14:23 +0200
committerJosé Fonseca <[email protected]>2010-04-19 18:14:23 +0200
commit150d12679d4d2550e0e54d76a43d153c4254ddfe (patch)
tree9d0a28e4472946e487c3f8b5716d433c43d3d9e2 /src/gallium/drivers/cell
parent2197fac47cb1f87387820678357cc67c9a2536b9 (diff)
cell: Implement index bias.
Diffstat (limited to 'src/gallium/drivers/cell')
-rw-r--r--src/gallium/drivers/cell/ppu/cell_draw_arrays.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/src/gallium/drivers/cell/ppu/cell_draw_arrays.c b/src/gallium/drivers/cell/ppu/cell_draw_arrays.c
index 80e94a79df7..b50a30bee80 100644
--- a/src/gallium/drivers/cell/ppu/cell_draw_arrays.c
+++ b/src/gallium/drivers/cell/ppu/cell_draw_arrays.c
@@ -59,6 +59,7 @@ static void
cell_draw_range_elements(struct pipe_context *pipe,
struct pipe_resource *indexBuffer,
unsigned indexSize,
+ int indexBias,
unsigned min_index,
unsigned max_index,
unsigned mode, unsigned start, unsigned count)
@@ -84,11 +85,11 @@ cell_draw_range_elements(struct pipe_context *pipe,
/* Map index buffer, if present */
if (indexBuffer) {
void *mapped_indexes = cell_resource(indexBuffer)->data;
- draw_set_mapped_element_buffer(draw, indexSize, mapped_indexes);
+ draw_set_mapped_element_buffer(draw, indexSize, indexBias, mapped_indexes);
}
else {
/* no index/element buffer */
- draw_set_mapped_element_buffer(draw, 0, NULL);
+ draw_set_mapped_element_buffer(draw, 0, 0, NULL);
}
@@ -117,11 +118,11 @@ cell_draw_range_elements(struct pipe_context *pipe,
static void
cell_draw_elements(struct pipe_context *pipe,
struct pipe_resource *indexBuffer,
- unsigned indexSize,
+ unsigned indexSize, int indexBias,
unsigned mode, unsigned start, unsigned count)
{
cell_draw_range_elements( pipe, indexBuffer,
- indexSize,
+ indexSize, indeBias,
0, 0xffffffff,
mode, start, count );
}
@@ -131,7 +132,7 @@ static void
cell_draw_arrays(struct pipe_context *pipe, unsigned mode,
unsigned start, unsigned count)
{
- cell_draw_elements(pipe, NULL, 0, mode, start, count);
+ cell_draw_elements(pipe, NULL, 0, 0, mode, start, count);
}