diff options
author | Brian <[email protected]> | 2008-02-18 16:19:05 -0700 |
---|---|---|
committer | Brian <[email protected]> | 2008-02-18 16:19:05 -0700 |
commit | aceeb80d4f706980aaf71b8e098d4c6718d8ac90 (patch) | |
tree | 23f402dc726b0f97e25e7b6e5d2c097362093ea0 /src/gallium/auxiliary/draw/draw_prim.c | |
parent | 0448dbd64a2ef217349f4ada4777d432bc82e46d (diff) |
gallium: antialiased line drawing
New draw/prim stage: draw_aaline. When installed, lines are replaced by
textured quads to do antialiasing. The current user-defined fragment shader
is modified to do a texture fetch and modulate fragment alpha.
Diffstat (limited to 'src/gallium/auxiliary/draw/draw_prim.c')
-rw-r--r-- | src/gallium/auxiliary/draw/draw_prim.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/gallium/auxiliary/draw/draw_prim.c b/src/gallium/auxiliary/draw/draw_prim.c index 51e2242719a..dd9a8488637 100644 --- a/src/gallium/auxiliary/draw/draw_prim.c +++ b/src/gallium/auxiliary/draw/draw_prim.c @@ -121,11 +121,15 @@ static void draw_prim_queue_flush( struct draw_context *draw ) void draw_do_flush( struct draw_context *draw, unsigned flags ) { + static boolean flushing = FALSE; + if (0) debug_printf("Flushing with %d verts, %d prims\n", draw->vs.queue_nr, draw->pq.queue_nr ); + if (!flushing) { + flushing = TRUE; if (flags >= DRAW_FLUSH_SHADER_QUEUE) { if (draw->vs.queue_nr) @@ -146,6 +150,9 @@ void draw_do_flush( struct draw_context *draw, unsigned flags ) } } } + + flushing = FALSE; + } } |