summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/mesa/vbo/vbo_attrib_tmp.h14
-rw-r--r--src/mesa/vbo/vbo_exec_api.c14
-rw-r--r--src/mesa/vbo/vbo_save_api.c14
3 files changed, 28 insertions, 14 deletions
diff --git a/src/mesa/vbo/vbo_attrib_tmp.h b/src/mesa/vbo/vbo_attrib_tmp.h
index 796b3883633..5c4beb540bf 100644
--- a/src/mesa/vbo/vbo_attrib_tmp.h
+++ b/src/mesa/vbo/vbo_attrib_tmp.h
@@ -522,20 +522,6 @@ TAG(MultiTexCoord4fv)(GLenum target, const GLfloat * v)
}
-/**
- * If index=0, does glVertexAttrib*() alias glVertex() to emit a vertex?
- * It depends on a few things, including whether we're inside or outside
- * of glBegin/glEnd.
- */
-static inline bool
-is_vertex_position(const struct gl_context *ctx, GLuint index)
-{
- return (index == 0 &&
- _mesa_attr_zero_aliases_vertex(ctx) &&
- _mesa_inside_begin_end(ctx));
-}
-
-
static void GLAPIENTRY
TAG(VertexAttrib1fARB)(GLuint index, GLfloat x)
{
diff --git a/src/mesa/vbo/vbo_exec_api.c b/src/mesa/vbo/vbo_exec_api.c
index 749a5ebe65a..5b1549d96de 100644
--- a/src/mesa/vbo/vbo_exec_api.c
+++ b/src/mesa/vbo/vbo_exec_api.c
@@ -458,6 +458,20 @@ vbo_exec_begin_vertices(struct gl_context *ctx)
/**
+ * If index=0, does glVertexAttrib*() alias glVertex() to emit a vertex?
+ * It depends on a few things, including whether we're inside or outside
+ * of glBegin/glEnd.
+ */
+static inline bool
+is_vertex_position(const struct gl_context *ctx, GLuint index)
+{
+ return (index == 0 &&
+ _mesa_attr_zero_aliases_vertex(ctx) &&
+ _mesa_inside_begin_end(ctx));
+}
+
+
+/**
* This macro is used to implement all the glVertex, glColor, glTexCoord,
* glVertexAttrib, etc functions.
* \param A VBO_ATTRIB_x attribute index
diff --git a/src/mesa/vbo/vbo_save_api.c b/src/mesa/vbo/vbo_save_api.c
index b33dfa5fd8e..d378bdb058d 100644
--- a/src/mesa/vbo/vbo_save_api.c
+++ b/src/mesa/vbo/vbo_save_api.c
@@ -979,6 +979,20 @@ reset_vertex(struct gl_context *ctx)
}
+/**
+ * If index=0, does glVertexAttrib*() alias glVertex() to emit a vertex?
+ * It depends on a few things, including whether we're inside or outside
+ * of glBegin/glEnd.
+ */
+static inline bool
+is_vertex_position(const struct gl_context *ctx, GLuint index)
+{
+ return (index == 0 &&
+ _mesa_attr_zero_aliases_vertex(ctx) &&
+ _mesa_inside_dlist_begin_end(ctx));
+}
+
+
#define ERROR(err) _mesa_compile_error(ctx, err, __func__);