[Mesa-dev] [PATCH 1/3] draw: Remove reduced_prim

Stéphane Marchesin marcheu at chromium.org
Tue Jan 24 20:47:12 PST 2012


From: Jakob Bornecrantz <wallbraker at gmail.com>

Conflicts:

	src/gallium/auxiliary/draw/draw_context.c

Reviewed-by: Stéphane Marchesin <marcheu at chromium.org>
Tested-by: Stéphane Marchesin <marcheu at chromium.org>
---
 src/gallium/auxiliary/draw/draw_context.c |    4 ----
 src/gallium/auxiliary/draw/draw_private.h |    2 --
 src/gallium/auxiliary/draw/draw_pt.c      |    6 ------
 3 files changed, 0 insertions(+), 12 deletions(-)

diff --git a/src/gallium/auxiliary/draw/draw_context.c b/src/gallium/auxiliary/draw/draw_context.c
index 7e554dc..4ce4445 100644
--- a/src/gallium/auxiliary/draw/draw_context.c
+++ b/src/gallium/auxiliary/draw/draw_context.c
@@ -155,8 +155,6 @@ boolean draw_init(struct draw_context *draw)
    draw->clip_z = TRUE;
 
    draw->pt.user.planes = (float (*) [DRAW_TOTAL_CLIP_PLANES][4]) &(draw->plane[0]);
-   draw->reduced_prim = ~0; /* != any of PIPE_PRIM_x */
-
 
    if (!draw_pipeline_init( draw ))
       return FALSE;
@@ -656,8 +654,6 @@ void draw_do_flush( struct draw_context *draw, unsigned flags )
 
       draw_pipeline_flush( draw, flags );
 
-      draw->reduced_prim = ~0; /* is reduced_prim needed any more? */
-      
       draw->flushing = FALSE;
    }
 }
diff --git a/src/gallium/auxiliary/draw/draw_private.h b/src/gallium/auxiliary/draw/draw_private.h
index 31beb4b..1a0286d 100644
--- a/src/gallium/auxiliary/draw/draw_private.h
+++ b/src/gallium/auxiliary/draw/draw_private.h
@@ -290,8 +290,6 @@ struct draw_context
       uint slot[10];
    } extra_shader_outputs;
 
-   unsigned reduced_prim;
-
    unsigned instance_id;
 
 #ifdef HAVE_LLVM
diff --git a/src/gallium/auxiliary/draw/draw_pt.c b/src/gallium/auxiliary/draw/draw_pt.c
index 080e03d..9a017fd 100644
--- a/src/gallium/auxiliary/draw/draw_pt.c
+++ b/src/gallium/auxiliary/draw/draw_pt.c
@@ -420,7 +420,6 @@ void
 draw_vbo(struct draw_context *draw,
          const struct pipe_draw_info *info)
 {
-   unsigned reduced_prim = u_reduced_prim(info->mode);
    unsigned instance;
    unsigned index_limit;
 
@@ -435,11 +434,6 @@ draw_vbo(struct draw_context *draw,
    draw->pt.user.min_index = info->min_index;
    draw->pt.user.max_index = info->max_index;
 
-   if (reduced_prim != draw->reduced_prim) {
-      draw_do_flush(draw, DRAW_FLUSH_STATE_CHANGE);
-      draw->reduced_prim = reduced_prim;
-   }
-
    if (0)
       debug_printf("draw_vbo(mode=%u start=%u count=%u):\n",
                    info->mode, info->start, info->count);
-- 
1.7.6.5



More information about the mesa-dev mailing list