summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/blend.c
diff options
context:
space:
mode:
authorMarek Olšák <[email protected]>2018-01-07 18:27:40 +0100
committerMarek Olšák <[email protected]>2018-02-02 15:06:47 +0100
commit51d36f5e02d7083e52b5617bf44de0105c611db4 (patch)
tree7b34e45497e7613d11537270ce964962ec437b42 /src/mesa/main/blend.c
parentdf1d5174fccc6771e24ef09e0cd77dfa377a7b6a (diff)
mesa: don't flag _NEW_COLOR for KHR adv.blend if prog constant doesn't change
This only affects drivers that set DriverFlags.NewBlend. v2: - fix typo advanded -> advanced - return "enum gl_advanced_blend_mode" from _mesa_get_advanced_blend_sh_constant - don't call FLUSH_VERTICES twice Reviewed-by: Ian Romanick <[email protected]>
Diffstat (limited to 'src/mesa/main/blend.c')
-rw-r--r--src/mesa/main/blend.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/mesa/main/blend.c b/src/mesa/main/blend.c
index 6b379f24992..ec8e27e1d4d 100644
--- a/src/mesa/main/blend.c
+++ b/src/mesa/main/blend.c
@@ -535,7 +535,8 @@ _mesa_BlendEquation( GLenum mode )
return;
}
- _mesa_flush_vertices_for_blend_state(ctx);
+ _mesa_flush_vertices_for_blend_adv(ctx, ctx->Color.BlendEnabled,
+ advanced_mode);
for (buf = 0; buf < numBuffers; buf++) {
ctx->Color.Blend[buf].EquationRGB = mode;
@@ -560,7 +561,8 @@ blend_equationi(struct gl_context *ctx, GLuint buf, GLenum mode,
ctx->Color.Blend[buf].EquationA == mode)
return; /* no change */
- _mesa_flush_vertices_for_blend_state(ctx);
+ _mesa_flush_vertices_for_blend_adv(ctx, ctx->Color.BlendEnabled,
+ advanced_mode);
ctx->Color.Blend[buf].EquationRGB = mode;
ctx->Color.Blend[buf].EquationA = mode;
ctx->Color._BlendEquationPerBuffer = GL_TRUE;