From 095c6699f449ed4803f23e844cc0227743a9c3e1 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Tue, 25 Apr 2006 00:21:32 +0000 Subject: No longer alias generic vertex attribs with conventional attribs for GL_ARB_vertex_program. --- src/mesa/main/vtxfmt.c | 23 +++++++++++++++-------- 1 file changed, 15 insertions(+), 8 deletions(-) (limited to 'src/mesa/main/vtxfmt.c') diff --git a/src/mesa/main/vtxfmt.c b/src/mesa/main/vtxfmt.c index b3c6398291..99583a20da 100644 --- a/src/mesa/main/vtxfmt.c +++ b/src/mesa/main/vtxfmt.c @@ -72,7 +72,10 @@ #include "vtxfmt_tmp.h" - +/** + * Use the per-vertex functions found in to initialze the given + * API dispatch table. + */ static void install_vtxfmt( struct _glapi_table *tab, const GLvertexformat *vfmt ) { @@ -124,6 +127,15 @@ install_vtxfmt( struct _glapi_table *tab, const GLvertexformat *vfmt ) SET_CallLists(tab, vfmt->CallLists); SET_Begin(tab, vfmt->Begin); SET_End(tab, vfmt->End); + SET_Rectf(tab, vfmt->Rectf); + SET_DrawArrays(tab, vfmt->DrawArrays); + SET_DrawElements(tab, vfmt->DrawElements); + SET_DrawRangeElements(tab, vfmt->DrawRangeElements); + SET_EvalMesh1(tab, vfmt->EvalMesh1); + SET_EvalMesh2(tab, vfmt->EvalMesh2); + ASSERT(tab->EvalMesh2); + + /* GL_NV_vertex_program */ SET_VertexAttrib1fNV(tab, vfmt->VertexAttrib1fNV); SET_VertexAttrib1fvNV(tab, vfmt->VertexAttrib1fvNV); SET_VertexAttrib2fNV(tab, vfmt->VertexAttrib2fNV); @@ -132,6 +144,7 @@ install_vtxfmt( struct _glapi_table *tab, const GLvertexformat *vfmt ) SET_VertexAttrib3fvNV(tab, vfmt->VertexAttrib3fvNV); SET_VertexAttrib4fNV(tab, vfmt->VertexAttrib4fNV); SET_VertexAttrib4fvNV(tab, vfmt->VertexAttrib4fvNV); +#if FEATURE_ARB_vertex_program SET_VertexAttrib1fARB(tab, vfmt->VertexAttrib1fARB); SET_VertexAttrib1fvARB(tab, vfmt->VertexAttrib1fvARB); SET_VertexAttrib2fARB(tab, vfmt->VertexAttrib2fARB); @@ -140,13 +153,7 @@ install_vtxfmt( struct _glapi_table *tab, const GLvertexformat *vfmt ) SET_VertexAttrib3fvARB(tab, vfmt->VertexAttrib3fvARB); SET_VertexAttrib4fARB(tab, vfmt->VertexAttrib4fARB); SET_VertexAttrib4fvARB(tab, vfmt->VertexAttrib4fvARB); - SET_Rectf(tab, vfmt->Rectf); - SET_DrawArrays(tab, vfmt->DrawArrays); - SET_DrawElements(tab, vfmt->DrawElements); - SET_DrawRangeElements(tab, vfmt->DrawRangeElements); - SET_EvalMesh1(tab, vfmt->EvalMesh1); - SET_EvalMesh2(tab, vfmt->EvalMesh2); - ASSERT(tab->EvalMesh2); +#endif } -- cgit v1.2.3