From 2b36db496d34c60a3f987fa88d52bf5684713240 Mon Sep 17 00:00:00 2001 From: Chia-I Wu Date: Mon, 7 Sep 2009 18:20:10 +0800 Subject: mesa/main: Make FEATURE_attrib_stack follow feature conventions. As shown in mfeatures.h, this allows users of attrib.h to work without knowing if the feature is available. --- src/mesa/main/attrib.c | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) (limited to 'src/mesa/main/attrib.c') diff --git a/src/mesa/main/attrib.c b/src/mesa/main/attrib.c index 0fb8fa3bba..246c5521b7 100644 --- a/src/mesa/main/attrib.c +++ b/src/mesa/main/attrib.c @@ -57,6 +57,7 @@ #include "varray.h" #include "viewport.h" #include "mtypes.h" +#include "glapi/dispatch.h" /** @@ -174,6 +175,9 @@ struct texture_state }; +#if FEATURE_attrib_stack + + /** * Allocate new attribute node of given type/kind. Attach payload data. * Insert it into the linked list named by 'head'. @@ -1464,6 +1468,19 @@ _mesa_PopClientAttrib(void) } +void +_mesa_init_attrib_dispatch(struct _glapi_table *disp) +{ + SET_PopAttrib(disp, _mesa_PopAttrib); + SET_PushAttrib(disp, _mesa_PushAttrib); + SET_PopClientAttrib(disp, _mesa_PopClientAttrib); + SET_PushClientAttrib(disp, _mesa_PushClientAttrib); +} + + +#endif /* FEATURE_attrib_stack */ + + /** * Free any attribute state data that might be attached to the context. */ -- cgit v1.2.3