diff options
author | Brian <[email protected]> | 2007-08-08 16:07:07 -0600 |
---|---|---|
committer | Brian <[email protected]> | 2007-08-08 16:10:40 -0600 |
commit | 6dc212ce49bd2939e905ea0bb8f2fa162cd67df6 (patch) | |
tree | d9ce2834190353efdd9b899b397ce12ed8a746eb /src/mesa | |
parent | 31132546891e0fd0f0fc889506fb5e46c0075c4c (diff) |
print_vertex func for debugging
Diffstat (limited to 'src/mesa')
-rw-r--r-- | src/mesa/pipe/softpipe/sp_prim_setup.c | 20 |
1 files changed, 19 insertions, 1 deletions
diff --git a/src/mesa/pipe/softpipe/sp_prim_setup.c b/src/mesa/pipe/softpipe/sp_prim_setup.c index c8046befa74..7a3d011b7bd 100644 --- a/src/mesa/pipe/softpipe/sp_prim_setup.c +++ b/src/mesa/pipe/softpipe/sp_prim_setup.c @@ -236,6 +236,18 @@ static void flush_spans( struct setup_stage *setup ) setup->span.right[1] = 0; } +#if 0 +static void print_vertex(const struct setup_stage *setup, + const struct vertex_header *v) +{ + int i; + printf("Vertex:\n"); + for (i = 0; i < setup->softpipe->nr_attrs; i++) { + printf(" %d: %f %f %f\n", i, + v->data[i][0], v->data[i][1], v->data[i][2]); + } +} +#endif static GLboolean setup_sort_vertices( struct setup_stage *setup, const struct prim_header *prim ) @@ -244,6 +256,13 @@ static GLboolean setup_sort_vertices( struct setup_stage *setup, const struct vertex_header *v1 = prim->v[1]; const struct vertex_header *v2 = prim->v[2]; +#if 0 + printf("Triangle:\n"); + print_vertex(setup, v0); + print_vertex(setup, v1); + print_vertex(setup, v2); +#endif + setup->vprovoke = v2; /* determine bottom to top order of vertices */ @@ -429,7 +448,6 @@ static void tri_persp_coeff( struct setup_stage *setup, } - /** * Compute the setup->coef[] array dadx, dady, a0 values. * Must be called after setup->vmin,vmid,vmax,vprovoke are initialized. |