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_validate.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_validate.c')
-rw-r--r-- | src/gallium/auxiliary/draw/draw_validate.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/gallium/auxiliary/draw/draw_validate.c b/src/gallium/auxiliary/draw/draw_validate.c index 4375ebabbc4..97e40e372b8 100644 --- a/src/gallium/auxiliary/draw/draw_validate.c +++ b/src/gallium/auxiliary/draw/draw_validate.c @@ -58,7 +58,13 @@ static struct draw_stage *validate_pipeline( struct draw_stage *stage ) * shorter pipelines for lines & points. */ - if ((draw->rasterizer->line_width != 1.0 && draw->convert_wide_lines) || + if (draw->rasterizer->line_smooth && draw->pipeline.aaline) { + draw->pipeline.aaline->next = next; + next = draw->pipeline.aaline; + } + + if ((draw->rasterizer->line_width != 1.0 && draw->convert_wide_lines + && !draw->rasterizer->line_smooth) || (draw->rasterizer->point_size != 1.0 && draw->convert_wide_points) || draw->rasterizer->point_sprite) { draw->pipeline.wide->next = next; |