diff options
author | Aapo Tahkola <[email protected]> | 2006-06-06 22:24:12 +0000 |
---|---|---|
committer | Aapo Tahkola <[email protected]> | 2006-06-06 22:24:12 +0000 |
commit | 9248882ca27b289180a76262aa3d9b26c0cb0e8b (patch) | |
tree | 4be41552706b53802d8a034e70c132d98cd7a827 /src/mesa/tnl/t_vp_build.c | |
parent | 9ba2006594a54173956b2af69055f633fa813bf8 (diff) |
prevent run_arb_vertex_program from running tnl programs unless ctx->_MaintainTnlProgram is set
Diffstat (limited to 'src/mesa/tnl/t_vp_build.c')
-rw-r--r-- | src/mesa/tnl/t_vp_build.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/mesa/tnl/t_vp_build.c b/src/mesa/tnl/t_vp_build.c index 6789fd38fb8..c2fd42c5332 100644 --- a/src/mesa/tnl/t_vp_build.c +++ b/src/mesa/tnl/t_vp_build.c @@ -1544,6 +1544,16 @@ void _tnl_UpdateFixedFunctionProgram( GLcontext *ctx ) ctx->VertexProgram._Current); } +void _tnl_ProgramCacheInit( GLcontext *ctx ) +{ + TNLcontext *tnl = TNL_CONTEXT(ctx); + + tnl->vp_cache = (struct tnl_cache *) MALLOC(sizeof(*tnl->vp_cache)); + tnl->vp_cache->size = 17; + tnl->vp_cache->n_items = 0; + tnl->vp_cache->items = (struct tnl_cache_item**) + _mesa_calloc(tnl->vp_cache->size * sizeof(*tnl->vp_cache->items)); +} void _tnl_ProgramCacheDestroy( GLcontext *ctx ) { |