ATTR4FV(index, v);
}
+#define ERROR_IF_NOT_PACKED_TYPE(ctx, type, func) \
+ if (type != GL_INT_2_10_10_10_REV && type != GL_UNSIGNED_INT_2_10_10_10_REV) { \
+ _mesa_error(ctx, GL_INVALID_ENUM, "%s(type)", func); \
+ return; \
+ }
static void GLAPIENTRY
TAG(VertexP2ui)(GLenum type, GLuint value)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glVertexP2ui");
ATTR_UI(ctx, 2, type, 0, VBO_ATTRIB_POS, value);
}
TAG(VertexP2uiv)(GLenum type, const GLuint *value)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glVertexP2uiv");
ATTR_UI(ctx, 2, type, 0, VBO_ATTRIB_POS, value[0]);
}
TAG(VertexP3ui)(GLenum type, GLuint value)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glVertexP3ui");
ATTR_UI(ctx, 3, type, 0, VBO_ATTRIB_POS, value);
}
TAG(VertexP3uiv)(GLenum type, const GLuint *value)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glVertexP3uiv");
ATTR_UI(ctx, 3, type, 0, VBO_ATTRIB_POS, value[0]);
}
TAG(VertexP4ui)(GLenum type, GLuint value)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glVertexP4ui");
ATTR_UI(ctx, 4, type, 0, VBO_ATTRIB_POS, value);
}
TAG(VertexP4uiv)(GLenum type, const GLuint *value)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glVertexP4uiv");
ATTR_UI(ctx, 4, type, 0, VBO_ATTRIB_POS, value[0]);
}
TAG(TexCoordP1ui)(GLenum type, GLuint coords)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glTexCoordP1ui");
ATTR_UI(ctx, 1, type, 0, VBO_ATTRIB_TEX0, coords);
}
TAG(TexCoordP1uiv)(GLenum type, const GLuint *coords)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glTexCoordP1uiv");
ATTR_UI(ctx, 1, type, 0, VBO_ATTRIB_TEX0, coords[0]);
}
TAG(TexCoordP2ui)(GLenum type, GLuint coords)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glTexCoordP2ui");
ATTR_UI(ctx, 2, type, 0, VBO_ATTRIB_TEX0, coords);
}
TAG(TexCoordP2uiv)(GLenum type, const GLuint *coords)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glTexCoordP2uiv");
ATTR_UI(ctx, 2, type, 0, VBO_ATTRIB_TEX0, coords[0]);
}
TAG(TexCoordP3ui)(GLenum type, GLuint coords)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glTexCoordP3ui");
ATTR_UI(ctx, 3, type, 0, VBO_ATTRIB_TEX0, coords);
}
TAG(TexCoordP3uiv)(GLenum type, const GLuint *coords)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glTexCoordP3uiv");
ATTR_UI(ctx, 3, type, 0, VBO_ATTRIB_TEX0, coords[0]);
}
TAG(TexCoordP4ui)(GLenum type, GLuint coords)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glTexCoordP4ui");
ATTR_UI(ctx, 4, type, 0, VBO_ATTRIB_TEX0, coords);
}
TAG(TexCoordP4uiv)(GLenum type, const GLuint *coords)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glTexCoordP4uiv");
ATTR_UI(ctx, 4, type, 0, VBO_ATTRIB_TEX0, coords[0]);
}
TAG(MultiTexCoordP1ui)(GLenum target, GLenum type, GLuint coords)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glMultiTexCoordP1ui");
GLuint attr = (target & 0x7) + VBO_ATTRIB_TEX0;
ATTR_UI(ctx, 1, type, 0, attr, coords);
}
TAG(MultiTexCoordP1uiv)(GLenum target, GLenum type, const GLuint *coords)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glMultiTexCoordP1uiv");
GLuint attr = (target & 0x7) + VBO_ATTRIB_TEX0;
ATTR_UI(ctx, 1, type, 0, attr, coords[0]);
}
TAG(MultiTexCoordP2ui)(GLenum target, GLenum type, GLuint coords)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glMultiTexCoordP2ui");
GLuint attr = (target & 0x7) + VBO_ATTRIB_TEX0;
ATTR_UI(ctx, 2, type, 0, attr, coords);
}
TAG(MultiTexCoordP2uiv)(GLenum target, GLenum type, const GLuint *coords)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glMultiTexCoordP2uiv");
GLuint attr = (target & 0x7) + VBO_ATTRIB_TEX0;
ATTR_UI(ctx, 2, type, 0, attr, coords[0]);
}
TAG(MultiTexCoordP3ui)(GLenum target, GLenum type, GLuint coords)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glMultiTexCoordP3ui");
GLuint attr = (target & 0x7) + VBO_ATTRIB_TEX0;
ATTR_UI(ctx, 3, type, 0, attr, coords);
}
TAG(MultiTexCoordP3uiv)(GLenum target, GLenum type, const GLuint *coords)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glMultiTexCoordP3uiv");
GLuint attr = (target & 0x7) + VBO_ATTRIB_TEX0;
ATTR_UI(ctx, 3, type, 0, attr, coords[0]);
}
TAG(MultiTexCoordP4ui)(GLenum target, GLenum type, GLuint coords)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glMultiTexCoordP4ui");
GLuint attr = (target & 0x7) + VBO_ATTRIB_TEX0;
ATTR_UI(ctx, 4, type, 0, attr, coords);
}
TAG(MultiTexCoordP4uiv)(GLenum target, GLenum type, const GLuint *coords)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glMultiTexCoordP4uiv");
GLuint attr = (target & 0x7) + VBO_ATTRIB_TEX0;
ATTR_UI(ctx, 4, type, 0, attr, coords[0]);
}
TAG(NormalP3ui)(GLenum type, GLuint coords)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glNormalP3ui");
ATTR_UI(ctx, 3, type, 1, VBO_ATTRIB_NORMAL, coords);
}
TAG(NormalP3uiv)(GLenum type, const GLuint *coords)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glNormalP3uiv");
ATTR_UI(ctx, 3, type, 1, VBO_ATTRIB_NORMAL, coords[0]);
}
TAG(ColorP3ui)(GLenum type, GLuint color)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glColorP3ui");
ATTR_UI(ctx, 3, type, 1, VBO_ATTRIB_COLOR0, color);
}
TAG(ColorP3uiv)(GLenum type, const GLuint *color)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glColorP3uiv");
ATTR_UI(ctx, 3, type, 1, VBO_ATTRIB_COLOR0, color[0]);
}
TAG(ColorP4ui)(GLenum type, GLuint color)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glColorP4ui");
ATTR_UI(ctx, 4, type, 1, VBO_ATTRIB_COLOR0, color);
}
TAG(ColorP4uiv)(GLenum type, const GLuint *color)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glColorP4uiv");
ATTR_UI(ctx, 4, type, 1, VBO_ATTRIB_COLOR0, color[0]);
}
TAG(SecondaryColorP3ui)(GLenum type, GLuint color)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glSecondaryColorP3ui");
ATTR_UI(ctx, 3, type, 1, VBO_ATTRIB_COLOR1, color);
}
TAG(SecondaryColorP3uiv)(GLenum type, const GLuint *color)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glSecondaryColorP3uiv");
ATTR_UI(ctx, 3, type, 1, VBO_ATTRIB_COLOR1, color[0]);
}
GLuint value)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glVertexAttribP1ui");
ATTR_UI_INDEX(ctx, 1, type, normalized, index, value);
}
GLuint value)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glVertexAttribP2ui");
ATTR_UI_INDEX(ctx, 2, type, normalized, index, value);
}
GLuint value)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glVertexAttribP3ui");
ATTR_UI_INDEX(ctx, 3, type, normalized, index, value);
}
GLuint value)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glVertexAttribP4ui");
ATTR_UI_INDEX(ctx, 4, type, normalized, index, value);
}
const GLuint *value)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glVertexAttribP1uiv");
ATTR_UI_INDEX(ctx, 1, type, normalized, index, *value);
}
const GLuint *value)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glVertexAttribP2uiv");
ATTR_UI_INDEX(ctx, 2, type, normalized, index, *value);
}
const GLuint *value)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glVertexAttribP3uiv");
ATTR_UI_INDEX(ctx, 3, type, normalized, index, *value);
}
const GLuint *value)
{
GET_CURRENT_CONTEXT(ctx);
+ ERROR_IF_NOT_PACKED_TYPE(ctx, type, "glVertexAttribP4uiv");
ATTR_UI_INDEX(ctx, 4, type, normalized, index, *value);
}