From 51b36396ae45f9ee9cec8d612787d038641dc6c8 Mon Sep 17 00:00:00 2001 From: Keith Whitwell Date: Mon, 4 Jun 2001 16:09:28 +0000 Subject: Adaptor code that lets tnl convert compiled (display list) cassettes back to glVertex() type calls. Allows driver-supplied tnl modules to avoid fallback on glCallList inside begin/end pairs. Still a little buggy... --- src/mesa/tnl/t_context.c | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) (limited to 'src/mesa/tnl/t_context.c') diff --git a/src/mesa/tnl/t_context.c b/src/mesa/tnl/t_context.c index 37b0483663..e842bd1422 100644 --- a/src/mesa/tnl/t_context.c +++ b/src/mesa/tnl/t_context.c @@ -1,4 +1,4 @@ -/* $Id: t_context.c,v 1.18 2001/05/11 08:11:31 keithw Exp $ */ +/* $Id: t_context.c,v 1.19 2001/06/04 16:09:28 keithw Exp $ */ /* * Mesa 3-D graphics library @@ -103,6 +103,7 @@ _tnl_CreateContext( GLcontext *ctx ) tnl->NeedProjCoords = GL_TRUE; + tnl->LoopbackDListCassettes = GL_FALSE; /* Hook our functions into exec and compile dispatch tables. */ @@ -123,6 +124,8 @@ _tnl_CreateContext( GLcontext *ctx ) tnl->Driver.RenderTabElts = _tnl_render_tab_elts; tnl->Driver.RenderTabVerts = _tnl_render_tab_verts; + + return GL_TRUE; } @@ -210,3 +213,12 @@ _tnl_need_projected_coords( GLcontext *ctx, GLboolean mode ) _tnl_InvalidateState( ctx, _NEW_PROJECTION ); } } + +void +_tnl_need_dlist_loopback( GLcontext *ctx, GLboolean mode ) +{ + TNLcontext *tnl = TNL_CONTEXT(ctx); + if (tnl->LoopbackDListCassettes != mode) { + tnl->LoopbackDListCassettes = mode; + } +} -- cgit v1.2.3