mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-06 09:28:07 +02:00
cso: don't pass blend_color through cso_context
It's never saved or restored. Redundant state changes are already filtered out by mesa/main. Reviewed-by: Eric Anholt <eric@anholt.net> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7940>
This commit is contained in:
parent
912ba743b5
commit
a35014954b
3 changed files with 2 additions and 16 deletions
|
|
@ -123,7 +123,6 @@ struct cso_context {
|
|||
|
||||
struct pipe_framebuffer_state fb, fb_saved;
|
||||
struct pipe_viewport_state vp, vp_saved;
|
||||
struct pipe_blend_color blend_color;
|
||||
unsigned sample_mask, sample_mask_saved;
|
||||
unsigned min_samples, min_samples_saved;
|
||||
struct pipe_stencil_ref stencil_ref, stencil_ref_saved;
|
||||
|
|
@ -798,16 +797,6 @@ cso_restore_viewport(struct cso_context *ctx)
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
void cso_set_blend_color(struct cso_context *ctx,
|
||||
const struct pipe_blend_color *bc)
|
||||
{
|
||||
if (memcmp(&ctx->blend_color, bc, sizeof(ctx->blend_color))) {
|
||||
ctx->blend_color = *bc;
|
||||
ctx->pipe->set_blend_color(ctx->pipe, bc);
|
||||
}
|
||||
}
|
||||
|
||||
void cso_set_sample_mask(struct cso_context *ctx, unsigned sample_mask)
|
||||
{
|
||||
if (ctx->sample_mask != sample_mask) {
|
||||
|
|
|
|||
|
|
@ -120,10 +120,6 @@ void cso_set_viewport(struct cso_context *cso,
|
|||
void cso_set_viewport_dims(struct cso_context *ctx,
|
||||
float width, float height, boolean invert);
|
||||
|
||||
|
||||
void cso_set_blend_color(struct cso_context *cso,
|
||||
const struct pipe_blend_color *bc);
|
||||
|
||||
void cso_set_sample_mask(struct cso_context *cso, unsigned stencil_mask);
|
||||
|
||||
void cso_set_min_samples(struct cso_context *cso, unsigned min_samples);
|
||||
|
|
|
|||
|
|
@ -303,8 +303,9 @@ st_update_blend( struct st_context *st )
|
|||
void
|
||||
st_update_blend_color(struct st_context *st)
|
||||
{
|
||||
struct pipe_context *pipe = st->pipe;
|
||||
struct pipe_blend_color bc;
|
||||
|
||||
COPY_4FV(bc.color, st->ctx->Color.BlendColorUnclamped);
|
||||
cso_set_blend_color(st->cso_context, &bc);
|
||||
pipe->set_blend_color(pipe, &bc);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue