mesa: refactor: move #define FEATURE flags into new mfeatures.h file
[mesa.git] / src / mesa / vbo / vbo_context.h
index 0dc1019b39fc3e5110ed01279b44f7d394328130..bf405eb69338fb44851b7111d1c77fc3a8b723f3 100644 (file)
 
 #include "vbo.h"
 #include "vbo_attrib.h"
-#include "vbo_save.h"
 #include "vbo_exec.h"
+#if FEATURE_dlist
+#include "vbo_save.h"
+#endif
 
 
 struct vbo_context {
@@ -74,7 +76,9 @@ struct vbo_context {
 
 
    struct vbo_exec_context exec;
+#if FEATURE_dlist
    struct vbo_save_context save;
+#endif
 
    /* Callback into the driver.  This must always succeed, the driver
     * is responsible for initiating any fallback actions required:
@@ -96,9 +100,9 @@ enum {
 
 static INLINE GLuint get_program_mode( GLcontext *ctx )
 {
-   if (!ctx->VertexProgram._Enabled)
+   if (!ctx->VertexProgram._Current)
       return VP_NONE;
-   else if (ctx->VertexProgram.Current->IsNVProgram)
+   else if (ctx->VertexProgram._Current->IsNVProgram)
       return VP_NV;
    else
       return VP_ARB;