aboutsummaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/r600/r600_shader.h
diff options
context:
space:
mode:
authorDave Airlie <[email protected]>2015-01-27 13:39:51 +1000
committerDave Airlie <[email protected]>2015-01-28 09:51:21 +1000
commit349df23eb0d119e3f22ff6149824497414f07505 (patch)
tree048b6c2ba1a2cfb032664e2ce2ee61ee6f214000 /src/gallium/drivers/r600/r600_shader.h
parentcc2fc095bfae1c0494240e4f06931e2ca90e182c (diff)
r600g: add support for primitive id without geom shader (v2)
GLSL 1.50 specifies a fragment shader may have a primitive id input without a geometry shader present. On r600 hw there is a special GS scenario for this, you have to enable GS_SCENARIO_A and pass the primitive id through the vertex shader which operates in GS_A mode. This is a first pass attempt at this, and passes the piglit tests that test for this. v1.1: clean up debug print + no need to assign key value to setup output. v2: add r600 support Reviewed-by: Glenn Kennard <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
Diffstat (limited to 'src/gallium/drivers/r600/r600_shader.h')
-rw-r--r--src/gallium/drivers/r600/r600_shader.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/gallium/drivers/r600/r600_shader.h b/src/gallium/drivers/r600/r600_shader.h
index ab67013d8c3..b2559e9b661 100644
--- a/src/gallium/drivers/r600/r600_shader.h
+++ b/src/gallium/drivers/r600/r600_shader.h
@@ -84,6 +84,8 @@ struct r600_shader {
unsigned max_arrays;
unsigned num_arrays;
unsigned vs_as_es;
+ unsigned vs_as_gs_a;
+ unsigned ps_prim_id_input;
struct r600_shader_array * arrays;
};
@@ -92,6 +94,8 @@ struct r600_shader_key {
unsigned alpha_to_one:1;
unsigned nr_cbufs:4;
unsigned vs_as_es:1;
+ unsigned vs_as_gs_a:1;
+ unsigned vs_prim_id_out:8;
};
struct r600_shader_array {