draw: implement primitive assembler
authorZack Rusin <zackr@vmware.com>
Thu, 18 Apr 2013 10:08:41 +0000 (03:08 -0700)
committerZack Rusin <zackr@vmware.com>
Thu, 18 Apr 2013 18:51:22 +0000 (11:51 -0700)
commit12eab7cc564a6928197f9b87ded9e368e56976f0
treee4d157930258f4cfe4ab173cf178ea9b7e51478f
parente4752d0f56b90a5565936b1e05bb48edb1baa3ac
draw: implement primitive assembler

Input assembler needs to be able to decompose adjacency primitives
into something that can be understood by the rest of the pipeline.
The specs say that the adjacency primitives are *only* visible
in the geometry shader, for everything else they need to be
decomposed. Which in most of the cases is not an issue, because
the geometry shader always decomposes them for us, but without
geometry shader we were passing unchanged adjacency primitives
to the rest of the pipeline and causing crashes everywhere. This
commit introduces a primitive assembler which, if geometry
shader is missing and the input primitive is one of the
adjacency primitives, decomposes them into something
that the rest of the pipeline can understand.

Signed-off-by: Zack Rusin <zackr@vmware.com>
Reviewed-by: Jose Fonseca <jfonseca@vmware.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Reviewed-by: Brian Paul <brianp@vmware.com>
src/gallium/auxiliary/Makefile.sources
src/gallium/auxiliary/draw/draw_prim_assembler.c [new file with mode: 0644]
src/gallium/auxiliary/draw/draw_prim_assembler.h [new file with mode: 0644]
src/gallium/auxiliary/draw/draw_prim_assembler_tmp.h [new file with mode: 0644]
src/gallium/auxiliary/draw/draw_pt_fetch_shade_pipeline.c
src/gallium/auxiliary/draw/draw_pt_fetch_shade_pipeline_llvm.c
src/gallium/auxiliary/util/u_prim.h