aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa/state_tracker/st_cb_program.c
diff options
context:
space:
mode:
authorBrian <[email protected]>2007-09-28 15:39:09 -0600
committerBrian <[email protected]>2007-09-28 15:39:39 -0600
commit636480cc9c7836daf879cb45644900922cf31f47 (patch)
treeb795e3dc8681bff9b3689efc8a1adb735eee7ebb /src/mesa/state_tracker/st_cb_program.c
parentf14ece2d2c9add5ebf21171746f34ce60ff0df3b (diff)
Instead of linked program pairs, keep a list of vertex programs translated for each fragment program.
Diffstat (limited to 'src/mesa/state_tracker/st_cb_program.c')
-rw-r--r--src/mesa/state_tracker/st_cb_program.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/mesa/state_tracker/st_cb_program.c b/src/mesa/state_tracker/st_cb_program.c
index 3a7ce9405e8..5c00dd1ae1c 100644
--- a/src/mesa/state_tracker/st_cb_program.c
+++ b/src/mesa/state_tracker/st_cb_program.c
@@ -165,6 +165,12 @@ static void st_program_string_notify( GLcontext *ctx,
stfp->serialNo++;
+ if (stfp->fs) {
+ /* free the TGSI code */
+ // cso_delete(stfp->vs);
+ stfp->fs = NULL;
+ }
+
stfp->param_state = stfp->Base.Base.Parameters->StateFlags;
}
else if (target == GL_VERTEX_PROGRAM_ARB) {
@@ -172,6 +178,12 @@ static void st_program_string_notify( GLcontext *ctx,
stvp->serialNo++;
+ if (stvp->vs) {
+ /* free the TGSI code */
+ // cso_delete(stfp->vs);
+ stvp->vs = NULL;
+ }
+
stvp->param_state = stvp->Base.Base.Parameters->StateFlags;
/* Also tell tnl about it: