draw: fixes for vertex shaders outputting layer or viewport index
authorRoland Scheidegger <sroland@vmware.com>
Tue, 18 Nov 2014 21:46:00 +0000 (22:46 +0100)
committerRoland Scheidegger <sroland@vmware.com>
Wed, 19 Nov 2014 17:35:30 +0000 (18:35 +0100)
commit4b6d6642d2c64ce67d65ead480fb99104a7e2d3a
treeacea1eac94a65c073a4545c0a15960d524a14b21
parent9460cd39e8c74a6a8aba7e5c57bb4929ab135c29
draw: fixes for vertex shaders outputting layer or viewport index

Mostly add a couple cases so we don't just check gs for this.
There's only one gotcha, the built-in vp transform in the llvm vs can't
handle it (this would be fixable though non-trivial due to vp index being
non-constant for the SoA outputs, but we don't use it if there's a gs
neither - the whole clip/vp transform integration there is suboptimal).

Reviewed-by: Jose Fonseca <jfonseca@vmware.com>
src/gallium/auxiliary/draw/draw_context.c
src/gallium/auxiliary/draw/draw_llvm.c
src/gallium/auxiliary/draw/draw_pt_fetch_shade_pipeline_llvm.c
src/gallium/auxiliary/draw/draw_pt_post_vs.c
src/gallium/auxiliary/draw/draw_vs.c
src/gallium/auxiliary/draw/draw_vs.h
src/gallium/auxiliary/tgsi/tgsi_scan.c