diff options
author | Rob Clark <[email protected]> | 2014-09-29 14:29:04 -0400 |
---|---|---|
committer | Rob Clark <[email protected]> | 2014-09-29 18:30:43 -0400 |
commit | dce96f6da2d8ec4c17403db57326731dcf9d6051 (patch) | |
tree | f67c855ab414c09186241410f37c224de910d911 /src/gallium/drivers/freedreno/a3xx/fd3_context.h | |
parent | 3aaab87563e40bdd8fb98494d7e3eb844521476c (diff) |
freedreno/a3xx: re-emit shaders on variant change
We need to keep track if a state change other than frag/vert shader
state will trigger us to need a different shader variant, and if
necessary mark the appropriate shader state as dirty. Otherwise we will
forget to re-emit the shader state.
Signed-off-by: Rob Clark <[email protected]>
Diffstat (limited to 'src/gallium/drivers/freedreno/a3xx/fd3_context.h')
-rw-r--r-- | src/gallium/drivers/freedreno/a3xx/fd3_context.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/gallium/drivers/freedreno/a3xx/fd3_context.h b/src/gallium/drivers/freedreno/a3xx/fd3_context.h index 48bbb47e9ca..2736470b93a 100644 --- a/src/gallium/drivers/freedreno/a3xx/fd3_context.h +++ b/src/gallium/drivers/freedreno/a3xx/fd3_context.h @@ -35,6 +35,9 @@ #include "freedreno_context.h" +#include "ir3_shader.h" + + struct fd3_context { struct fd_context base; @@ -86,6 +89,12 @@ struct fd3_context { * shader: */ unsigned fsaturate_s, fsaturate_t, fsaturate_r; + + /* some state changes require a different shader variant. Keep + * track of this so we know when we need to re-emit shader state + * due to variant change. See fixup_shader_state() + */ + struct ir3_shader_key last_key; }; static INLINE struct fd3_context * |