aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa/main/dlist.c
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2011-05-25 20:44:35 -0600
committerBrian Paul <[email protected]>2011-05-25 20:44:35 -0600
commit95fa22c8640abd2f5694631aaa079ce815cef7d1 (patch)
tree105e1fe4918145c850a63c4ed615786a5e8a12d9 /src/mesa/main/dlist.c
parent001aa6c979f7795d8e48344c662a0546ae555f95 (diff)
mesa: display list support for glProgramParameteriARB()
Diffstat (limited to 'src/mesa/main/dlist.c')
-rw-r--r--src/mesa/main/dlist.c30
1 files changed, 30 insertions, 0 deletions
diff --git a/src/mesa/main/dlist.c b/src/mesa/main/dlist.c
index 4bfcb6bc80d..2532e166d16 100644
--- a/src/mesa/main/dlist.c
+++ b/src/mesa/main/dlist.c
@@ -447,6 +447,9 @@ typedef enum
OPCODE_SAMPLER_PARAMETERIIV,
OPCODE_SAMPLER_PARAMETERUIV,
+ /* GL_ARB_geometry_shader4 */
+ OPCODE_PROGRAM_PARAMETERI,
+
/* The following three are meta instructions */
OPCODE_ERROR, /* raise compiled-in error */
OPCODE_CONTINUE,
@@ -7205,6 +7208,25 @@ save_SamplerParameterIuiv(GLuint sampler, GLenum pname, const GLuint *params)
}
}
+/* GL_ARB_geometry_shader4 */
+static void GLAPIENTRY
+save_ProgramParameteri(GLuint program, GLenum pname, GLint value)
+{
+ Node *n;
+ GET_CURRENT_CONTEXT(ctx);
+ ASSERT_OUTSIDE_SAVE_BEGIN_END_AND_FLUSH(ctx);
+ n = alloc_instruction(ctx, OPCODE_PROGRAM_PARAMETERI, 3);
+ if (n) {
+ n[1].ui = program;
+ n[2].e = pname;
+ n[3].i = value;
+ }
+ if (ctx->ExecuteFlag) {
+ CALL_ProgramParameteriARB(ctx->Exec, (program, pname, value));
+ }
+}
+
+
/**
* Save an error-generating command into display list.
*
@@ -8432,6 +8454,11 @@ execute_list(struct gl_context *ctx, GLuint list)
}
break;
+ /* GL_ARB_geometry_shader4 */
+ case OPCODE_PROGRAM_PARAMETERI:
+ CALL_ProgramParameteriARB(ctx->Exec, (n[1].ui, n[2].e, n[3].i));
+ break;
+
case OPCODE_CONTINUE:
n = (Node *) n[1].next;
break;
@@ -10126,6 +10153,9 @@ _mesa_create_save_table(void)
SET_BlendEquationiARB(table, save_BlendEquationi);
SET_BlendEquationSeparateiARB(table, save_BlendEquationSeparatei);
+ /* GL_ARB_geometry_shader4 */
+ SET_ProgramParameteriARB(table, save_ProgramParameteri);
+
return table;
}