aboutsummaryrefslogtreecommitdiff
path: root/mesalib/src/mesa/main/varray.h
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2014-05-11 17:43:25 +0200
committermarha <marha@users.sourceforge.net>2014-05-11 17:43:25 +0200
commit26dfcdba6c306d6312c598e4191449302329be68 (patch)
tree2bf56b5a0eb2cc554833fdc6e08f2b59f1bfdabd /mesalib/src/mesa/main/varray.h
parent2dc2880eacae3d52f4ab4bb5ec43c5bbf50c5c3f (diff)
parentae06feae7876db47ff0e1fde40cf4a324a412037 (diff)
downloadvcxsrv-26dfcdba6c306d6312c598e4191449302329be68.tar.gz
vcxsrv-26dfcdba6c306d6312c598e4191449302329be68.tar.bz2
vcxsrv-26dfcdba6c306d6312c598e4191449302329be68.zip
Merge remote-tracking branch 'origin/released'
Conflicts: mesalib/src/mesa/main/imports.h
Diffstat (limited to 'mesalib/src/mesa/main/varray.h')
-rw-r--r--mesalib/src/mesa/main/varray.h20
1 files changed, 20 insertions, 0 deletions
diff --git a/mesalib/src/mesa/main/varray.h b/mesalib/src/mesa/main/varray.h
index bc820ed23..f94ebac99 100644
--- a/mesalib/src/mesa/main/varray.h
+++ b/mesalib/src/mesa/main/varray.h
@@ -106,6 +106,22 @@ _mesa_update_client_array(struct gl_context *ctx,
_mesa_reference_buffer_object(ctx, &dst->BufferObj, binding->BufferObj);
}
+static inline bool
+_mesa_attr_zero_aliases_vertex(struct gl_context *ctx)
+{
+ const bool is_forward_compatible_context =
+ ctx->Const.ContextFlags & GL_CONTEXT_FLAG_FORWARD_COMPATIBLE_BIT;
+
+ /* In OpenGL 3.1 attribute 0 becomes non-magic, just like in OpenGL ES
+ * 2.0. Note that we cannot just check for API_OPENGL_COMPAT here because
+ * that will erroneously allow this usage in a 3.0 forward-compatible
+ * context too.
+ */
+ return (ctx->API == API_OPENGLES
+ || (ctx->API == API_OPENGL_COMPAT
+ && !is_forward_compatible_context));
+}
+
extern void GLAPIENTRY
_mesa_VertexPointer(GLint size, GLenum type, GLsizei stride,
const GLvoid *ptr);
@@ -291,6 +307,10 @@ _mesa_BindVertexBuffer(GLuint bindingIndex, GLuint buffer, GLintptr offset,
GLsizei stride);
extern void GLAPIENTRY
+_mesa_BindVertexBuffers(GLuint first, GLsizei count, const GLuint *buffers,
+ const GLintptr *offsets, const GLsizei *strides);
+
+extern void GLAPIENTRY
_mesa_VertexAttribFormat(GLuint attribIndex, GLint size, GLenum type,
GLboolean normalized, GLuint relativeOffset);