diff options
author | Timothy Arceri <[email protected]> | 2016-11-04 09:25:36 +1100 |
---|---|---|
committer | Timothy Arceri <[email protected]> | 2017-01-06 11:21:42 +1100 |
commit | c46a630000a2539e38a448f24a456397ce201a2e (patch) | |
tree | a9c8fc697557c5821225c4001fbc33c84c64b09a /src/mesa/main/api_validate.c | |
parent | 6e3f6097c995a74d4ce52f542413b01ff819c203 (diff) |
mesa: make _CurrentFragmentProgram a gl_program struct pointer
Making this point to a gl_program struct rather than a gl_shader_program
struct will allow use to later also make the CurrentProgram array hold
gl_program structs which in turn will allow for code simpilifcation.
Reviewed-by: Eric Anholt <[email protected]>
Diffstat (limited to 'src/mesa/main/api_validate.c')
-rw-r--r-- | src/mesa/main/api_validate.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/mesa/main/api_validate.c b/src/mesa/main/api_validate.c index 42eeeba1414..5f051dbec6f 100644 --- a/src/mesa/main/api_validate.c +++ b/src/mesa/main/api_validate.c @@ -99,10 +99,8 @@ check_blend_func_error(struct gl_context *ctx) * the blend equation or "blend_support_all_equations", the error * INVALID_OPERATION is generated [...]" */ - const struct gl_shader_program *sh_prog = - ctx->_Shader->_CurrentFragmentProgram; - const GLbitfield blend_support = !sh_prog ? 0 : - sh_prog->_LinkedShaders[MESA_SHADER_FRAGMENT]->Program->sh.fs.BlendSupport; + const struct gl_program *prog = ctx->_Shader->_CurrentFragmentProgram; + const GLbitfield blend_support = !prog ? 0 : prog->sh.fs.BlendSupport; if ((blend_support & ctx->Color._AdvancedBlendMode) == 0) { _mesa_error(ctx, GL_INVALID_OPERATION, |