asahi: Track scissor states
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11084>
This commit is contained in:
parent
38a9c59377
commit
be5ea29237
|
@ -407,11 +407,18 @@ agx_set_sample_mask(struct pipe_context *pipe, unsigned sample_mask)
|
|||
}
|
||||
|
||||
static void
|
||||
agx_set_scissor_states(struct pipe_context *ctx,
|
||||
agx_set_scissor_states(struct pipe_context *pctx,
|
||||
unsigned start_slot,
|
||||
unsigned num_scissors,
|
||||
const struct pipe_scissor_state *state)
|
||||
const struct pipe_scissor_state *scissor)
|
||||
{
|
||||
struct agx_context *ctx = agx_context(pctx);
|
||||
|
||||
assert(start_slot == 0 && "no geometry shaders");
|
||||
assert(num_scissors == 1 && "no geometry shaders");
|
||||
|
||||
ctx->scissor = *scissor;
|
||||
ctx->dirty |= AGX_DIRTY_SCISSOR;
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
|
@ -117,6 +117,7 @@ struct asahi_shader_key {
|
|||
enum agx_dirty {
|
||||
AGX_DIRTY_VERTEX = BITFIELD_BIT(0),
|
||||
AGX_DIRTY_VIEWPORT = BITFIELD_BIT(1),
|
||||
AGX_DIRTY_SCISSOR = BITFIELD_BIT(2),
|
||||
};
|
||||
|
||||
struct agx_context {
|
||||
|
@ -136,6 +137,7 @@ struct agx_context {
|
|||
struct agx_blend *blend;
|
||||
struct pipe_blend_color blend_color;
|
||||
struct pipe_viewport_state viewport;
|
||||
struct pipe_scissor_state scissor;
|
||||
|
||||
uint8_t render_target[8][AGX_RENDER_TARGET_LENGTH];
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue