summaryrefslogtreecommitdiff
path: root/src/gallium/drivers/softpipe/sp_prim_vbuf.c
diff options
context:
space:
mode:
authorBrian Paul <brianp@vmware.com>2009-10-07 13:17:20 -0600
committerBrian Paul <brianp@vmware.com>2009-10-07 13:17:20 -0600
commit9a0ff33ad60cb63d430c4f93f6531f7aa2ec2ba8 (patch)
tree16cf86c42af0180a18ee227e50b59c7313d05d28 /src/gallium/drivers/softpipe/sp_prim_vbuf.c
parentcf6209b274c83f3018c9f0855de769285325b98f (diff)
softpipe: prefix non-static functions with sp_
Diffstat (limited to 'src/gallium/drivers/softpipe/sp_prim_vbuf.c')
-rw-r--r--src/gallium/drivers/softpipe/sp_prim_vbuf.c86
1 files changed, 43 insertions, 43 deletions
diff --git a/src/gallium/drivers/softpipe/sp_prim_vbuf.c b/src/gallium/drivers/softpipe/sp_prim_vbuf.c
index e603c20fc4..5fbac06a53 100644
--- a/src/gallium/drivers/softpipe/sp_prim_vbuf.c
+++ b/src/gallium/drivers/softpipe/sp_prim_vbuf.c
@@ -138,7 +138,7 @@ sp_vbuf_set_primitive(struct vbuf_render *vbr, unsigned prim)
struct softpipe_vbuf_render *cvbr = softpipe_vbuf_render(vbr);
struct setup_context *setup_ctx = cvbr->setup;
- setup_prepare( setup_ctx );
+ sp_setup_prepare( setup_ctx );
cvbr->softpipe->reduced_prim = u_reduced_prim(prim);
cvbr->prim = prim;
@@ -171,14 +171,14 @@ sp_vbuf_draw(struct vbuf_render *vbr, const ushort *indices, uint nr)
switch (cvbr->prim) {
case PIPE_PRIM_POINTS:
for (i = 0; i < nr; i++) {
- setup_point( setup_ctx,
+ sp_setup_point( setup_ctx,
get_vert(vertex_buffer, indices[i-0], stride) );
}
break;
case PIPE_PRIM_LINES:
for (i = 1; i < nr; i += 2) {
- setup_line( setup_ctx,
+ sp_setup_line( setup_ctx,
get_vert(vertex_buffer, indices[i-1], stride),
get_vert(vertex_buffer, indices[i-0], stride) );
}
@@ -186,7 +186,7 @@ sp_vbuf_draw(struct vbuf_render *vbr, const ushort *indices, uint nr)
case PIPE_PRIM_LINE_STRIP:
for (i = 1; i < nr; i ++) {
- setup_line( setup_ctx,
+ sp_setup_line( setup_ctx,
get_vert(vertex_buffer, indices[i-1], stride),
get_vert(vertex_buffer, indices[i-0], stride) );
}
@@ -194,12 +194,12 @@ sp_vbuf_draw(struct vbuf_render *vbr, const ushort *indices, uint nr)
case PIPE_PRIM_LINE_LOOP:
for (i = 1; i < nr; i ++) {
- setup_line( setup_ctx,
+ sp_setup_line( setup_ctx,
get_vert(vertex_buffer, indices[i-1], stride),
get_vert(vertex_buffer, indices[i-0], stride) );
}
if (nr) {
- setup_line( setup_ctx,
+ sp_setup_line( setup_ctx,
get_vert(vertex_buffer, indices[nr-1], stride),
get_vert(vertex_buffer, indices[0], stride) );
}
@@ -208,7 +208,7 @@ sp_vbuf_draw(struct vbuf_render *vbr, const ushort *indices, uint nr)
case PIPE_PRIM_TRIANGLES:
if (softpipe->rasterizer->flatshade_first) {
for (i = 2; i < nr; i += 3) {
- setup_tri( setup_ctx,
+ sp_setup_tri( setup_ctx,
get_vert(vertex_buffer, indices[i-1], stride),
get_vert(vertex_buffer, indices[i-0], stride),
get_vert(vertex_buffer, indices[i-2], stride) );
@@ -216,7 +216,7 @@ sp_vbuf_draw(struct vbuf_render *vbr, const ushort *indices, uint nr)
}
else {
for (i = 2; i < nr; i += 3) {
- setup_tri( setup_ctx,
+ sp_setup_tri( setup_ctx,
get_vert(vertex_buffer, indices[i-2], stride),
get_vert(vertex_buffer, indices[i-1], stride),
get_vert(vertex_buffer, indices[i-0], stride) );
@@ -227,7 +227,7 @@ sp_vbuf_draw(struct vbuf_render *vbr, const ushort *indices, uint nr)
case PIPE_PRIM_TRIANGLE_STRIP:
if (softpipe->rasterizer->flatshade_first) {
for (i = 2; i < nr; i += 1) {
- setup_tri( setup_ctx,
+ sp_setup_tri( setup_ctx,
get_vert(vertex_buffer, indices[i+(i&1)-1], stride),
get_vert(vertex_buffer, indices[i-(i&1)], stride),
get_vert(vertex_buffer, indices[i-2], stride) );
@@ -235,7 +235,7 @@ sp_vbuf_draw(struct vbuf_render *vbr, const ushort *indices, uint nr)
}
else {
for (i = 2; i < nr; i += 1) {
- setup_tri( setup_ctx,
+ sp_setup_tri( setup_ctx,
get_vert(vertex_buffer, indices[i+(i&1)-2], stride),
get_vert(vertex_buffer, indices[i-(i&1)-1], stride),
get_vert(vertex_buffer, indices[i-0], stride) );
@@ -246,7 +246,7 @@ sp_vbuf_draw(struct vbuf_render *vbr, const ushort *indices, uint nr)
case PIPE_PRIM_TRIANGLE_FAN:
if (softpipe->rasterizer->flatshade_first) {
for (i = 2; i < nr; i += 1) {
- setup_tri( setup_ctx,
+ sp_setup_tri( setup_ctx,
get_vert(vertex_buffer, indices[i-0], stride),
get_vert(vertex_buffer, indices[0], stride),
get_vert(vertex_buffer, indices[i-1], stride) );
@@ -254,7 +254,7 @@ sp_vbuf_draw(struct vbuf_render *vbr, const ushort *indices, uint nr)
}
else {
for (i = 2; i < nr; i += 1) {
- setup_tri( setup_ctx,
+ sp_setup_tri( setup_ctx,
get_vert(vertex_buffer, indices[0], stride),
get_vert(vertex_buffer, indices[i-1], stride),
get_vert(vertex_buffer, indices[i-0], stride) );
@@ -265,11 +265,11 @@ sp_vbuf_draw(struct vbuf_render *vbr, const ushort *indices, uint nr)
case PIPE_PRIM_QUADS:
if (softpipe->rasterizer->flatshade_first) {
for (i = 3; i < nr; i += 4) {
- setup_tri( setup_ctx,
+ sp_setup_tri( setup_ctx,
get_vert(vertex_buffer, indices[i-2], stride),
get_vert(vertex_buffer, indices[i-1], stride),
get_vert(vertex_buffer, indices[i-3], stride) );
- setup_tri( setup_ctx,
+ sp_setup_tri( setup_ctx,
get_vert(vertex_buffer, indices[i-1], stride),
get_vert(vertex_buffer, indices[i-0], stride),
get_vert(vertex_buffer, indices[i-3], stride) );
@@ -277,12 +277,12 @@ sp_vbuf_draw(struct vbuf_render *vbr, const ushort *indices, uint nr)
}
else {
for (i = 3; i < nr; i += 4) {
- setup_tri( setup_ctx,
+ sp_setup_tri( setup_ctx,
get_vert(vertex_buffer, indices[i-3], stride),
get_vert(vertex_buffer, indices[i-2], stride),
get_vert(vertex_buffer, indices[i-0], stride) );
- setup_tri( setup_ctx,
+ sp_setup_tri( setup_ctx,
get_vert(vertex_buffer, indices[i-2], stride),
get_vert(vertex_buffer, indices[i-1], stride),
get_vert(vertex_buffer, indices[i-0], stride) );
@@ -293,11 +293,11 @@ sp_vbuf_draw(struct vbuf_render *vbr, const ushort *indices, uint nr)
case PIPE_PRIM_QUAD_STRIP:
if (softpipe->rasterizer->flatshade_first) {
for (i = 3; i < nr; i += 2) {
- setup_tri( setup_ctx,
+ sp_setup_tri( setup_ctx,
get_vert(vertex_buffer, indices[i-0], stride),
get_vert(vertex_buffer, indices[i-1], stride),
get_vert(vertex_buffer, indices[i-3], stride));
- setup_tri( setup_ctx,
+ sp_setup_tri( setup_ctx,
get_vert(vertex_buffer, indices[i-2], stride),
get_vert(vertex_buffer, indices[i-0], stride),
get_vert(vertex_buffer, indices[i-3], stride) );
@@ -305,11 +305,11 @@ sp_vbuf_draw(struct vbuf_render *vbr, const ushort *indices, uint nr)
}
else {
for (i = 3; i < nr; i += 2) {
- setup_tri( setup_ctx,
+ sp_setup_tri( setup_ctx,
get_vert(vertex_buffer, indices[i-3], stride),
get_vert(vertex_buffer, indices[i-2], stride),
get_vert(vertex_buffer, indices[i-0], stride) );
- setup_tri( setup_ctx,
+ sp_setup_tri( setup_ctx,
get_vert(vertex_buffer, indices[i-1], stride),
get_vert(vertex_buffer, indices[i-3], stride),
get_vert(vertex_buffer, indices[i-0], stride) );
@@ -324,7 +324,7 @@ sp_vbuf_draw(struct vbuf_render *vbr, const ushort *indices, uint nr)
* flatshade_first state makes no difference.
*/
for (i = 2; i < nr; i += 1) {
- setup_tri( setup_ctx,
+ sp_setup_tri( setup_ctx,
get_vert(vertex_buffer, indices[i-0], stride),
get_vert(vertex_buffer, indices[i-1], stride),
get_vert(vertex_buffer, indices[0], stride) );
@@ -355,14 +355,14 @@ sp_vbuf_draw_arrays(struct vbuf_render *vbr, uint start, uint nr)
switch (cvbr->prim) {
case PIPE_PRIM_POINTS:
for (i = 0; i < nr; i++) {
- setup_point( setup_ctx,
+ sp_setup_point( setup_ctx,
get_vert(vertex_buffer, i-0, stride) );
}
break;
case PIPE_PRIM_LINES:
for (i = 1; i < nr; i += 2) {
- setup_line( setup_ctx,
+ sp_setup_line( setup_ctx,
get_vert(vertex_buffer, i-1, stride),
get_vert(vertex_buffer, i-0, stride) );
}
@@ -370,7 +370,7 @@ sp_vbuf_draw_arrays(struct vbuf_render *vbr, uint start, uint nr)
case PIPE_PRIM_LINE_STRIP:
for (i = 1; i < nr; i ++) {
- setup_line( setup_ctx,
+ sp_setup_line( setup_ctx,
get_vert(vertex_buffer, i-1, stride),
get_vert(vertex_buffer, i-0, stride) );
}
@@ -378,12 +378,12 @@ sp_vbuf_draw_arrays(struct vbuf_render *vbr, uint start, uint nr)
case PIPE_PRIM_LINE_LOOP:
for (i = 1; i < nr; i ++) {
- setup_line( setup_ctx,
+ sp_setup_line( setup_ctx,
get_vert(vertex_buffer, i-1, stride),
get_vert(vertex_buffer, i-0, stride) );
}
if (nr) {
- setup_line( setup_ctx,
+ sp_setup_line( setup_ctx,
get_vert(vertex_buffer, nr-1, stride),
get_vert(vertex_buffer, 0, stride) );
}
@@ -392,7 +392,7 @@ sp_vbuf_draw_arrays(struct vbuf_render *vbr, uint start, uint nr)
case PIPE_PRIM_TRIANGLES:
if (softpipe->rasterizer->flatshade_first) {
for (i = 2; i < nr; i += 3) {
- setup_tri( setup_ctx,
+ sp_setup_tri( setup_ctx,
get_vert(vertex_buffer, i-1, stride),
get_vert(vertex_buffer, i-0, stride),
get_vert(vertex_buffer, i-2, stride) );
@@ -400,7 +400,7 @@ sp_vbuf_draw_arrays(struct vbuf_render *vbr, uint start, uint nr)
}
else {
for (i = 2; i < nr; i += 3) {
- setup_tri( setup_ctx,
+ sp_setup_tri( setup_ctx,
get_vert(vertex_buffer, i-2, stride),
get_vert(vertex_buffer, i-1, stride),
get_vert(vertex_buffer, i-0, stride) );
@@ -411,7 +411,7 @@ sp_vbuf_draw_arrays(struct vbuf_render *vbr, uint start, uint nr)
case PIPE_PRIM_TRIANGLE_STRIP:
if (softpipe->rasterizer->flatshade_first) {
for (i = 2; i < nr; i++) {
- setup_tri( setup_ctx,
+ sp_setup_tri( setup_ctx,
get_vert(vertex_buffer, i+(i&1)-1, stride),
get_vert(vertex_buffer, i-(i&1), stride),
get_vert(vertex_buffer, i-2, stride) );
@@ -419,7 +419,7 @@ sp_vbuf_draw_arrays(struct vbuf_render *vbr, uint start, uint nr)
}
else {
for (i = 2; i < nr; i++) {
- setup_tri( setup_ctx,
+ sp_setup_tri( setup_ctx,
get_vert(vertex_buffer, i+(i&1)-2, stride),
get_vert(vertex_buffer, i-(i&1)-1, stride),
get_vert(vertex_buffer, i-0, stride) );
@@ -430,7 +430,7 @@ sp_vbuf_draw_arrays(struct vbuf_render *vbr, uint start, uint nr)
case PIPE_PRIM_TRIANGLE_FAN:
if (softpipe->rasterizer->flatshade_first) {
for (i = 2; i < nr; i += 1) {
- setup_tri( setup_ctx,
+ sp_setup_tri( setup_ctx,
get_vert(vertex_buffer, i-0, stride),
get_vert(vertex_buffer, 0, stride),
get_vert(vertex_buffer, i-1, stride) );
@@ -438,7 +438,7 @@ sp_vbuf_draw_arrays(struct vbuf_render *vbr, uint start, uint nr)
}
else {
for (i = 2; i < nr; i += 1) {
- setup_tri( setup_ctx,
+ sp_setup_tri( setup_ctx,
get_vert(vertex_buffer, 0, stride),
get_vert(vertex_buffer, i-1, stride),
get_vert(vertex_buffer, i-0, stride) );
@@ -449,11 +449,11 @@ sp_vbuf_draw_arrays(struct vbuf_render *vbr, uint start, uint nr)
case PIPE_PRIM_QUADS:
if (softpipe->rasterizer->flatshade_first) {
for (i = 3; i < nr; i += 4) {
- setup_tri( setup_ctx,
+ sp_setup_tri( setup_ctx,
get_vert(vertex_buffer, i-2, stride),
get_vert(vertex_buffer, i-1, stride),
get_vert(vertex_buffer, i-3, stride) );
- setup_tri( setup_ctx,
+ sp_setup_tri( setup_ctx,
get_vert(vertex_buffer, i-1, stride),
get_vert(vertex_buffer, i-0, stride),
get_vert(vertex_buffer, i-3, stride) );
@@ -461,11 +461,11 @@ sp_vbuf_draw_arrays(struct vbuf_render *vbr, uint start, uint nr)
}
else {
for (i = 3; i < nr; i += 4) {
- setup_tri( setup_ctx,
+ sp_setup_tri( setup_ctx,
get_vert(vertex_buffer, i-3, stride),
get_vert(vertex_buffer, i-2, stride),
get_vert(vertex_buffer, i-0, stride) );
- setup_tri( setup_ctx,
+ sp_setup_tri( setup_ctx,
get_vert(vertex_buffer, i-2, stride),
get_vert(vertex_buffer, i-1, stride),
get_vert(vertex_buffer, i-0, stride) );
@@ -476,11 +476,11 @@ sp_vbuf_draw_arrays(struct vbuf_render *vbr, uint start, uint nr)
case PIPE_PRIM_QUAD_STRIP:
if (softpipe->rasterizer->flatshade_first) {
for (i = 3; i < nr; i += 2) {
- setup_tri( setup_ctx,
+ sp_setup_tri( setup_ctx,
get_vert(vertex_buffer, i-0, stride),
get_vert(vertex_buffer, i-1, stride),
get_vert(vertex_buffer, i-3, stride) );
- setup_tri( setup_ctx,
+ sp_setup_tri( setup_ctx,
get_vert(vertex_buffer, i-2, stride),
get_vert(vertex_buffer, i-0, stride),
get_vert(vertex_buffer, i-3, stride) );
@@ -488,11 +488,11 @@ sp_vbuf_draw_arrays(struct vbuf_render *vbr, uint start, uint nr)
}
else {
for (i = 3; i < nr; i += 2) {
- setup_tri( setup_ctx,
+ sp_setup_tri( setup_ctx,
get_vert(vertex_buffer, i-3, stride),
get_vert(vertex_buffer, i-2, stride),
get_vert(vertex_buffer, i-0, stride) );
- setup_tri( setup_ctx,
+ sp_setup_tri( setup_ctx,
get_vert(vertex_buffer, i-1, stride),
get_vert(vertex_buffer, i-3, stride),
get_vert(vertex_buffer, i-0, stride) );
@@ -507,7 +507,7 @@ sp_vbuf_draw_arrays(struct vbuf_render *vbr, uint start, uint nr)
* flatshade_first state makes no difference.
*/
for (i = 2; i < nr; i += 1) {
- setup_tri( setup_ctx,
+ sp_setup_tri( setup_ctx,
get_vert(vertex_buffer, i-1, stride),
get_vert(vertex_buffer, i-0, stride),
get_vert(vertex_buffer, 0, stride) );
@@ -525,7 +525,7 @@ static void
sp_vbuf_destroy(struct vbuf_render *vbr)
{
struct softpipe_vbuf_render *cvbr = softpipe_vbuf_render(vbr);
- setup_destroy_context(cvbr->setup);
+ sp_setup_destroy_context(cvbr->setup);
FREE(cvbr);
}
@@ -556,7 +556,7 @@ sp_create_vbuf_backend(struct softpipe_context *sp)
cvbr->softpipe = sp;
- cvbr->setup = setup_create_context(cvbr->softpipe);
+ cvbr->setup = sp_setup_create_context(cvbr->softpipe);
return &cvbr->base;
}