From 4d841fbaae3eac04f33f6a52f3dd829cfb1913b5 Mon Sep 17 00:00:00 2001 From: Rob Clark Date: Mon, 17 Apr 2017 10:56:20 -0400 Subject: freedreno: core SSBO support The generation-independent support for binding shader buffer objects. Signed-off-by: Rob Clark --- src/gallium/drivers/freedreno/freedreno_context.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src/gallium/drivers/freedreno/freedreno_context.h') diff --git a/src/gallium/drivers/freedreno/freedreno_context.h b/src/gallium/drivers/freedreno/freedreno_context.h index b50e66c90a9..7e940bca496 100644 --- a/src/gallium/drivers/freedreno/freedreno_context.h +++ b/src/gallium/drivers/freedreno/freedreno_context.h @@ -72,6 +72,12 @@ struct fd_constbuf_stateobj { uint32_t dirty_mask; }; +struct fd_shaderbuf_stateobj { + struct pipe_shader_buffer sb[PIPE_MAX_SHADER_BUFFERS]; + uint32_t enabled_mask; + uint32_t dirty_mask; +}; + struct fd_vertexbuf_stateobj { struct pipe_vertex_buffer vb[PIPE_MAX_ATTRIBS]; unsigned count; @@ -142,6 +148,7 @@ enum fd_dirty_shader_state { FD_DIRTY_SHADER_PROG = BIT(0), FD_DIRTY_SHADER_CONST = BIT(1), FD_DIRTY_SHADER_TEX = BIT(2), + FD_DIRTY_SHADER_SSBO = BIT(3), }; struct fd_context { @@ -264,6 +271,7 @@ struct fd_context { struct pipe_poly_stipple stipple; struct pipe_viewport_state viewport; struct fd_constbuf_stateobj constbuf[PIPE_SHADER_TYPES]; + struct fd_shaderbuf_stateobj shaderbuf[PIPE_SHADER_TYPES]; struct pipe_index_buffer indexbuf; struct fd_streamout_stateobj streamout; struct pipe_clip_state ucp; -- cgit v1.2.3