summaryrefslogtreecommitdiff
path: root/src/mesa/pipe/draw
diff options
context:
space:
mode:
authorZack Rusin <zack@tungstengraphics.com>2007-10-24 08:34:01 -0400
committerZack Rusin <zack@tungstengraphics.com>2007-10-24 11:21:05 -0400
commitd76a7b61bb2de2425289f462e07a678cf3c4ba59 (patch)
tree1d29b47fde67578acab60d1ae55bfb88ea8fe2ff /src/mesa/pipe/draw
parent5040eefbb758fb0e02125ad3a6bfb3dba13cb7fa (diff)
Cleanup some code.
Diffstat (limited to 'src/mesa/pipe/draw')
-rw-r--r--src/mesa/pipe/draw/draw_private.h2
-rw-r--r--src/mesa/pipe/draw/draw_vertex_fetch.c4
-rw-r--r--src/mesa/pipe/draw/draw_vertex_shader.c7
-rw-r--r--src/mesa/pipe/draw/draw_vertex_shader_llvm.c4
4 files changed, 15 insertions, 2 deletions
diff --git a/src/mesa/pipe/draw/draw_private.h b/src/mesa/pipe/draw/draw_private.h
index b672cc2e8b..e4c0551124 100644
--- a/src/mesa/pipe/draw/draw_private.h
+++ b/src/mesa/pipe/draw/draw_private.h
@@ -251,7 +251,9 @@ extern void draw_vertex_cache_reset_vertex_ids( struct draw_context *draw );
extern void draw_vertex_shader_queue_flush( struct draw_context *draw );
+#ifdef MESA_LLVM
extern void draw_vertex_shader_queue_flush_llvm( struct draw_context *draw );
+#endif
struct tgsi_exec_machine;
diff --git a/src/mesa/pipe/draw/draw_vertex_fetch.c b/src/mesa/pipe/draw/draw_vertex_fetch.c
index 1b093b7342..de1cd06da6 100644
--- a/src/mesa/pipe/draw/draw_vertex_fetch.c
+++ b/src/mesa/pipe/draw/draw_vertex_fetch.c
@@ -96,7 +96,7 @@ void draw_vertex_fetch( struct draw_context *draw,
for (j = 0; j < count; j++) {
uint attr;
- printf("fetch vertex %u: \n", j);
+ /*printf("fetch vertex %u: \n", j);*/
/* loop over vertex attributes (vertex shader inputs) */
for (attr = 0; attr < draw->vertex_shader->state->num_inputs; attr++) {
@@ -111,7 +111,7 @@ void draw_vertex_fetch( struct draw_context *draw,
fetch_attrib4(src, draw->vertex_element[attr].src_format, p);
- printf("> %u: %f %f %f %f\n", attr, p[0], p[1], p[2], p[3]);
+ /*printf(" %u: %f %f %f %f\n", attr, p[0], p[1], p[2], p[3]);*/
/* Transform to AoS xxxx/yyyy/zzzz/wwww representation:
*/
diff --git a/src/mesa/pipe/draw/draw_vertex_shader.c b/src/mesa/pipe/draw/draw_vertex_shader.c
index fb20dfa4e1..24cbf20fc7 100644
--- a/src/mesa/pipe/draw/draw_vertex_shader.c
+++ b/src/mesa/pipe/draw/draw_vertex_shader.c
@@ -161,6 +161,10 @@ run_vertex_program(struct draw_context *draw,
vOut[j]->data[slot][3] = machine->Outputs[slot].xyzw[3].f[j];
#if DBG
printf("output[%d][%d]: %f %f %f %f\n", j, slot,
+ vOut[j]->data[slot][0],
+ vOut[j]->data[slot][1],
+ vOut[j]->data[slot][2],
+ vOut[j]->data[slot][3]);
#endif
}
} /* loop over vertices */
@@ -175,10 +179,13 @@ void draw_vertex_shader_queue_flush( struct draw_context *draw )
{
unsigned i, j;
+// fprintf(stderr, " q(%d) ", draw->vs.queue_nr );
+#ifdef MESA_LLVM
if (draw->vertex_shader->state->llvm_prog) {
draw_vertex_shader_queue_flush_llvm(draw);
return;
}
+#endif
/* run vertex shader on vertex cache entries, four per invokation */
for (i = 0; i < draw->vs.queue_nr; i += 4) {
diff --git a/src/mesa/pipe/draw/draw_vertex_shader_llvm.c b/src/mesa/pipe/draw/draw_vertex_shader_llvm.c
index bcc44f7980..99f0aca9e5 100644
--- a/src/mesa/pipe/draw/draw_vertex_shader_llvm.c
+++ b/src/mesa/pipe/draw/draw_vertex_shader_llvm.c
@@ -35,6 +35,8 @@
#include "draw_context.h"
#include "draw_vertex.h"
+#ifdef MESA_LLVM
+
#include "pipe/llvm/llvmtgsi.h"
#include "pipe/tgsi/exec/tgsi_core.h"
@@ -199,3 +201,5 @@ void draw_vertex_shader_queue_flush_llvm(struct draw_context *draw)
draw->vs.queue_nr = 0;
}
+
+#endif /* MESA_LLVM */