diff options
author | Samuel Pitoiset <[email protected]> | 2016-01-05 23:53:30 +0100 |
---|---|---|
committer | Samuel Pitoiset <[email protected]> | 2016-02-13 16:01:01 +0100 |
commit | 805d92e54038255c145e464670d3352276ae27a9 (patch) | |
tree | 743ca7564b0b88a5786a896bf93ea45989290ea5 /src/mesa/state_tracker/st_atom_atomicbuf.c | |
parent | 61c87cd2c0698fad68e4a02c44cdcbd4fd00191a (diff) |
st/mesa: add state validation for compute shaders
This binds atomics, constants, samplers, ssbos, textures and ubos.
Signed-off-by: Samuel Pitoiset <[email protected]>
Reviewed-by: Marek Olšák <[email protected]>
Reviewed-by: Ilia Mirkin <[email protected]>
Diffstat (limited to 'src/mesa/state_tracker/st_atom_atomicbuf.c')
-rw-r--r-- | src/mesa/state_tracker/st_atom_atomicbuf.c | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/src/mesa/state_tracker/st_atom_atomicbuf.c b/src/mesa/state_tracker/st_atom_atomicbuf.c index 1c30d1fb701..d83c3960640 100644 --- a/src/mesa/state_tracker/st_atom_atomicbuf.c +++ b/src/mesa/state_tracker/st_atom_atomicbuf.c @@ -156,3 +156,21 @@ const struct st_tracked_state st_bind_tes_atomics = { }, bind_tes_atomics }; + +static void +bind_cs_atomics(struct st_context *st) +{ + struct gl_shader_program *prog = + st->ctx->_Shader->CurrentProgram[MESA_SHADER_COMPUTE]; + + st_bind_atomics(st, prog, PIPE_SHADER_COMPUTE); +} + +const struct st_tracked_state st_bind_cs_atomics = { + "st_bind_cs_atomics", + { + 0, + ST_NEW_COMPUTE_PROGRAM | ST_NEW_ATOMIC_BUFFER, + }, + bind_cs_atomics +}; |