Lines Matching defs:size
292 /* vertex_formats[gltype - GL_BYTE][integer*2 + normalized][size - 1] */
476 * Return a PIPE_FORMAT_x for the given GL datatype and size.
479 vertex_format_to_pipe_format(GLubyte size, GLenum16 type, GLenum16 format,
482 assert(size >= 1 && size <= 4);
487 return PIPE_FORMAT_R64_UINT + size - 1;
495 assert(size == 4 && !integer);
511 assert(size == 4 && !integer);
527 assert(size == 3 && !integer && format == GL_RGBA);
542 return vertex_formats[type - GL_BYTE][index][size-1];
547 GLubyte size, GLenum16 type, GLenum16 format,
551 assert(size <= 4);
554 vertex_format->Size = size;
558 vertex_format->_ElementSize = _mesa_bytes_per_vertex_attrib(size, type);
561 vertex_format_to_pipe_format(size, type, format, normalized, integer,
617 get_array_format(const struct gl_context *ctx, GLint sizeMax, GLint *size)
621 /* Do size parameter checking.
622 * If sizeMax = BGRA_OR_4 it means that size = GL_BGRA is legal and
626 *size == GL_BGRA) {
628 *size = 4;
637 * \param size Components per element (1, 2, 3 or 4)
649 gl_vert_attrib attrib, GLint size, GLenum type,
658 assert(size <= 4);
660 _mesa_set_vertex_format(&new_format, size, type, format,
684 * \param sizeMin Min allowable size value
685 * \param sizeMax Max allowable size value (may also be BGRA_OR_4)
686 * \param size Components per element (1, 2, 3 or 4)
699 GLint size, GLenum type, bool normalized,
739 * • size is BGRA and type is not UNSIGNED_BYTE, INT_2_10_10_10_REV
742 * • size is BGRA and normalized is FALSE;"
755 _mesa_error(ctx, GL_INVALID_OPERATION, "%s(size=GL_BGRA and type=%s)",
762 "%s(size=GL_BGRA and normalized=GL_FALSE)", func);
766 else if (size < sizeMin || size > sizeMax || size > 4) {
767 _mesa_error(ctx, GL_INVALID_VALUE, "%s(size=%d)", func, size);
773 type == GL_INT_2_10_10_10_REV) && size != 4) {
774 _mesa_error(ctx, GL_INVALID_OPERATION, "%s(size=%d)", func, size);
792 type == GL_UNSIGNED_INT_10F_11F_11F_REV && size != 3) {
793 _mesa_error(ctx, GL_INVALID_OPERATION, "%s(size=%d)", func, size);
808 * \param sizeMin min allowable size value
809 * \param sizeMax max allowable size value (may also be BGRA_OR_4)
810 * \param size components per element (1, 2, 3 or 4)
824 GLint size, GLenum type, GLsizei stride,
882 GLint size, GLenum type, GLsizei stride,
887 size, type, stride, normalized, integer, doubles, ptr);
890 sizeMax, size, type, normalized, integer,
902 * \param sizeMax max allowable size value (may also be BGRA_OR_4)
903 * \param size components per element (1, 2, 3 or 4)
917 GLint size, GLenum type, GLsizei stride,
921 _mesa_update_array_format(ctx, vao, attrib, size, type, format,
984 _mesa_VertexPointer_no_error(GLint size, GLenum type, GLsizei stride,
990 VERT_ATTRIB_POS, GL_RGBA, 4, size, type, stride,
996 _mesa_VertexPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *ptr)
1010 VERT_ATTRIB_POS, legalTypes, 2, 4, size,
1016 VERT_ATTRIB_POS, format, 4, size, type, stride,
1022 _mesa_VertexArrayVertexOffsetEXT(GLuint vaobj, GLuint buffer, GLint size,
1045 VERT_ATTRIB_POS, legalTypes, 2, 4, size,
1051 VERT_ATTRIB_POS, format, 4, size, type, stride,
1129 _mesa_ColorPointer_no_error(GLint size, GLenum type, GLsizei stride,
1134 GLenum format = get_array_format(ctx, BGRA_OR_4, &size);
1136 VERT_ATTRIB_COLOR0, format, BGRA_OR_4, size,
1142 _mesa_ColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *ptr)
1147 GLenum format = get_array_format(ctx, BGRA_OR_4, &size);
1160 BGRA_OR_4, size, type, stride, GL_TRUE,
1165 VERT_ATTRIB_COLOR0, format, BGRA_OR_4, size,
1171 _mesa_VertexArrayColorOffsetEXT(GLuint vaobj, GLuint buffer, GLint size,
1177 GLenum format = get_array_format(ctx, BGRA_OR_4, &size);
1198 BGRA_OR_4, size, type, stride, GL_TRUE,
1203 VERT_ATTRIB_COLOR0, format, BGRA_OR_4, size,
1335 _mesa_SecondaryColorPointer_no_error(GLint size, GLenum type,
1340 GLenum format = get_array_format(ctx, BGRA_OR_4, &size);
1342 VERT_ATTRIB_COLOR1, format, BGRA_OR_4, size, type,
1348 _mesa_SecondaryColorPointer(GLint size, GLenum type,
1353 GLenum format = get_array_format(ctx, BGRA_OR_4, &size);
1364 BGRA_OR_4, size, type, stride,
1369 VERT_ATTRIB_COLOR1, format, BGRA_OR_4, size, type,
1375 _mesa_VertexArraySecondaryColorOffsetEXT(GLuint vaobj, GLuint buffer, GLint size,
1380 GLenum format = get_array_format(ctx, BGRA_OR_4, &size);
1399 BGRA_OR_4, size, type, stride,
1404 VERT_ATTRIB_COLOR1, format, BGRA_OR_4, size, type,
1410 _mesa_TexCoordPointer_no_error(GLint size, GLenum type, GLsizei stride,
1417 VERT_ATTRIB_TEX(unit), GL_RGBA, 4, size, type,
1423 _mesa_TexCoordPointer(GLint size, GLenum type, GLsizei stride,
1441 sizeMin, 4, size, type, stride,
1446 VERT_ATTRIB_TEX(unit), format, 4, size, type,
1452 _mesa_VertexArrayTexCoordOffsetEXT(GLuint vaobj, GLuint buffer, GLint size,
1478 sizeMin, 4, size, type, stride,
1483 VERT_ATTRIB_TEX(unit), format, 4, size, type,
1490 GLint size, GLenum type, GLsizei stride,
1522 sizeMin, 4, size, type, stride,
1527 VERT_ATTRIB_TEX(unit), format, 4, size, type,
1640 _mesa_VertexAttribPointer_no_error(GLuint index, GLint size, GLenum type,
1646 GLenum format = get_array_format(ctx, BGRA_OR_4, &size);
1649 size, type, stride, normalized, GL_FALSE, GL_FALSE, ptr);
1659 _mesa_VertexAttribPointer(GLuint index, GLint size, GLenum type,
1665 GLenum format = get_array_format(ctx, BGRA_OR_4, &size);
1683 1, BGRA_OR_4, size, type, stride,
1689 size, type, stride, normalized, GL_FALSE, GL_FALSE, ptr);
1694 _mesa_VertexArrayVertexAttribOffsetEXT(GLuint vaobj, GLuint buffer, GLuint index, GLint size,
1699 GLenum format = get_array_format(ctx, BGRA_OR_4, &size);
1725 1, BGRA_OR_4, size, type, stride,
1731 size, type, stride, normalized, GL_FALSE, GL_FALSE, (void*) offset);
1736 _mesa_VertexArrayVertexAttribLOffsetEXT(GLuint vaobj, GLuint buffer, GLuint index, GLint size,
1759 1, 4, size, type, stride,
1765 size, type, stride, GL_FALSE, GL_FALSE, GL_TRUE, (void*) offset);
1770 _mesa_VertexAttribIPointer_no_error(GLuint index, GLint size, GLenum type,
1778 VERT_ATTRIB_GENERIC(index), GL_RGBA, 4, size, type,
1790 _mesa_VertexAttribIPointer(GLuint index, GLint size, GLenum type,
1810 1, 4, size, type, stride,
1815 VERT_ATTRIB_GENERIC(index), format, 4, size, type,
1821 _mesa_VertexAttribLPointer_no_error(GLuint index, GLint size, GLenum type,
1827 VERT_ATTRIB_GENERIC(index), GL_RGBA, 4, size, type,
1833 _mesa_VertexArrayVertexAttribIOffsetEXT(GLuint vaobj, GLuint buffer, GLuint index, GLint size,
1861 1, 4, size, type, stride,
1866 VERT_ATTRIB_GENERIC(index), format, 4, size, type,
1872 _mesa_VertexAttribLPointer(GLuint index, GLint size, GLenum type,
1888 1, 4, size, type, stride,
1893 VERT_ATTRIB_GENERIC(index), format, 4, size, type,
2497 _mesa_VertexPointerEXT(GLint size, GLenum type, GLsizei stride,
2501 _mesa_VertexPointer(size, type, stride, ptr);
2515 _mesa_ColorPointerEXT(GLint size, GLenum type, GLsizei stride, GLsizei count,
2519 _mesa_ColorPointer(size, type, stride, ptr);
2533 _mesa_TexCoordPointerEXT(GLint size, GLenum type, GLsizei stride,
2537 _mesa_TexCoordPointer(size, type, stride, ptr);
2542 _mesa_MultiTexCoordPointerEXT(GLenum texunit, GLint size, GLenum type,
2558 sizeMin, 4, size, type, stride,
2563 VERT_ATTRIB_TEX(unit), format, 4, size, type,
3373 vertex_attrib_format(GLuint attribIndex, GLint size, GLenum type,
3382 GLenum format = get_array_format(ctx, sizeMax, &size);
3420 legalTypes, 1, sizeMax, size, type,
3428 VERT_ATTRIB_GENERIC(attribIndex), size, type,
3435 _mesa_VertexAttribFormat(GLuint attribIndex, GLint size, GLenum type,
3438 vertex_attrib_format(attribIndex, size, type, normalized,
3446 _mesa_VertexAttribIFormat(GLuint attribIndex, GLint size, GLenum type,
3449 vertex_attrib_format(attribIndex, size, type, GL_FALSE,
3456 _mesa_VertexAttribLFormat(GLuint attribIndex, GLint size, GLenum type,
3459 vertex_attrib_format(attribIndex, size, type, GL_FALSE, GL_FALSE,
3467 GLint size, GLenum type, GLboolean normalized,
3477 GLenum format = get_array_format(ctx, sizeMax, &size);
3502 legalTypes, 1, sizeMax, size, type,
3509 _mesa_update_array_format(ctx, vao, VERT_ATTRIB_GENERIC(attribIndex), size,
3516 _mesa_VertexArrayAttribFormat(GLuint vaobj, GLuint attribIndex, GLint size,
3520 vertex_array_attrib_format(vaobj, false, attribIndex, size, type, normalized,
3528 _mesa_VertexArrayVertexAttribFormatEXT(GLuint vaobj, GLuint attribIndex, GLint size,
3532 vertex_array_attrib_format(vaobj, true, attribIndex, size, type, normalized,
3541 GLint size, GLenum type,
3544 vertex_array_attrib_format(vaobj, false, attribIndex, size, type, GL_FALSE,
3553 GLint size, GLenum type,
3556 vertex_array_attrib_format(vaobj, true, attribIndex, size, type, GL_FALSE,
3565 GLint size, GLenum type,
3568 vertex_array_attrib_format(vaobj, false, attribIndex, size, type, GL_FALSE,
3577 GLint size, GLenum type,
3580 vertex_array_attrib_format(vaobj, true, attribIndex, size, type, GL_FALSE,
3856 * \param size number of components (1, 2, 3 or 4) per attribute
3862 gl_vert_attrib index, GLint size, GLint type)
3869 _mesa_set_vertex_format(&array->Format, size, type, GL_RGBA,