aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa/state_tracker/st_cb_program.c
diff options
context:
space:
mode:
authormichal <michal@michal-laptop.(none)>2007-08-24 17:51:12 +0100
committermichal <michal@michal-laptop.(none)>2007-08-24 17:51:12 +0100
commit4fd7bc00f06a98e1db2ad886a13566f19895e3c0 (patch)
tree1bc1703dd3d8cc5ea14aa6e5605619e266d8361f /src/mesa/state_tracker/st_cb_program.c
parent2c7b74725bfbd0a022ebfada4736d6cb8ac28047 (diff)
Hook-up SSE2 to VS.
Diffstat (limited to 'src/mesa/state_tracker/st_cb_program.c')
-rw-r--r--src/mesa/state_tracker/st_cb_program.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/mesa/state_tracker/st_cb_program.c b/src/mesa/state_tracker/st_cb_program.c
index d0344efa0c3..25da720d865 100644
--- a/src/mesa/state_tracker/st_cb_program.c
+++ b/src/mesa/state_tracker/st_cb_program.c
@@ -77,6 +77,10 @@ static struct gl_program *st_new_program( GLcontext *ctx,
prog->id = program_id++;
prog->dirty = 1;
+#if defined(USE_X86_ASM) || defined(SLANG_X86)
+ x86_init_func( &prog->sse2_program );
+#endif
+
return _mesa_init_vertex_program( ctx,
&prog->Base,
target,
@@ -105,6 +109,16 @@ static struct gl_program *st_new_program( GLcontext *ctx,
static void st_delete_program( GLcontext *ctx,
struct gl_program *prog )
{
+ switch( prog->Target ) {
+ case GL_VERTEX_PROGRAM_ARB:
+ {
+ struct st_vertex_program *p = (struct st_vertex_program *) prog;
+
+ x86_release_func( &p->sse2_program );
+ break;
+ }
+
+ }
_mesa_delete_program( ctx, prog );
}