Lines Matching refs:vao
137 struct gl_vertex_array_object *vao) in update_attribute_map_mode() argument
146 const GLbitfield enabled = vao->Enabled; in update_attribute_map_mode()
148 vao->_AttributeMapMode = ATTRIBUTE_MAP_MODE_GENERIC0; in update_attribute_map_mode()
150 vao->_AttributeMapMode = ATTRIBUTE_MAP_MODE_POSITION; in update_attribute_map_mode()
152 vao->_AttributeMapMode = ATTRIBUTE_MAP_MODE_IDENTITY; in update_attribute_map_mode()
162 struct gl_vertex_array_object *vao, in _mesa_vertex_attrib_binding() argument
166 struct gl_array_attributes *array = &vao->VertexAttrib[attribIndex]; in _mesa_vertex_attrib_binding()
167 assert(!vao->SharedAndImmutable); in _mesa_vertex_attrib_binding()
172 if (vao->BufferBinding[bindingIndex].BufferObj) in _mesa_vertex_attrib_binding()
173 vao->VertexAttribBufferMask |= array_bit; in _mesa_vertex_attrib_binding()
175 vao->VertexAttribBufferMask &= ~array_bit; in _mesa_vertex_attrib_binding()
177 if (vao->BufferBinding[bindingIndex].InstanceDivisor) in _mesa_vertex_attrib_binding()
178 vao->NonZeroDivisorMask |= array_bit; in _mesa_vertex_attrib_binding()
180 vao->NonZeroDivisorMask &= ~array_bit; in _mesa_vertex_attrib_binding()
182 vao->BufferBinding[array->BufferBindingIndex]._BoundArrays &= ~array_bit; in _mesa_vertex_attrib_binding()
183 vao->BufferBinding[bindingIndex]._BoundArrays |= array_bit; in _mesa_vertex_attrib_binding()
187 vao->NewArrays |= vao->Enabled & array_bit; in _mesa_vertex_attrib_binding()
198 struct gl_vertex_array_object *vao, in _mesa_bind_vertex_buffer() argument
204 assert(index < ARRAY_SIZE(vao->BufferBinding)); in _mesa_bind_vertex_buffer()
205 assert(!vao->SharedAndImmutable); in _mesa_bind_vertex_buffer()
206 struct gl_vertex_buffer_binding *binding = &vao->BufferBinding[index]; in _mesa_bind_vertex_buffer()
237 vao->VertexAttribBufferMask &= ~binding->_BoundArrays; in _mesa_bind_vertex_buffer()
239 vao->VertexAttribBufferMask |= binding->_BoundArrays; in _mesa_bind_vertex_buffer()
243 vao->NewArrays |= vao->Enabled & binding->_BoundArrays; in _mesa_bind_vertex_buffer()
254 struct gl_vertex_array_object *vao, in vertex_binding_divisor() argument
259 &vao->BufferBinding[bindingIndex]; in vertex_binding_divisor()
260 assert(!vao->SharedAndImmutable); in vertex_binding_divisor()
266 vao->NonZeroDivisorMask |= binding->_BoundArrays; in vertex_binding_divisor()
268 vao->NonZeroDivisorMask &= ~binding->_BoundArrays; in vertex_binding_divisor()
270 vao->NewArrays |= vao->Enabled & binding->_BoundArrays; in vertex_binding_divisor()
628 struct gl_vertex_array_object *vao, in _mesa_update_array_format() argument
634 struct gl_array_attributes *const array = &vao->VertexAttrib[attrib]; in _mesa_update_array_format()
637 assert(!vao->SharedAndImmutable); in _mesa_update_array_format()
650 vao->NewArrays |= vao->Enabled & VERT_BIT(attrib); in _mesa_update_array_format()
673 struct gl_vertex_array_object *vao, in validate_array_format() argument
797 struct gl_vertex_array_object *vao, in validate_array() argument
815 if (ctx->API == API_OPENGL_CORE && (vao == ctx->Array.DefaultVAO)) { in validate_array()
845 if (ptr != NULL && vao != ctx->Array.DefaultVAO && in validate_array()
855 struct gl_vertex_array_object *vao, in validate_array_and_format() argument
863 validate_array(ctx, func, vao, obj, attrib, legalTypes, sizeMin, sizeMax, in validate_array_and_format()
866 return validate_array_format(ctx, func, vao, attrib, legalTypes, sizeMin, in validate_array_and_format()
890 struct gl_vertex_array_object *vao, in update_array() argument
898 _mesa_update_array_format(ctx, vao, attrib, size, type, format, in update_array()
902 _mesa_vertex_attrib_binding(ctx, vao, attrib, attrib); in update_array()
905 struct gl_array_attributes *array = &vao->VertexAttrib[attrib]; in update_array()
909 vao->NewArrays |= vao->Enabled & VERT_BIT(attrib); in update_array()
915 _mesa_bind_vertex_buffer(ctx, vao, attrib, in update_array()
926 struct gl_vertex_array_object** vao, in _lookup_vao_and_vbo_dsa() argument
930 *vao = _mesa_lookup_vao_err(ctx, vaobj, true, caller); in _lookup_vao_and_vbo_dsa()
931 if (!(*vao)) in _lookup_vao_and_vbo_dsa()
1004 struct gl_vertex_array_object* vao; in _mesa_VertexArrayVertexOffsetEXT() local
1008 &vao, &vbo, in _mesa_VertexArrayVertexOffsetEXT()
1013 vao, vbo, in _mesa_VertexArrayVertexOffsetEXT()
1019 update_array(ctx, vao, vbo, in _mesa_VertexArrayVertexOffsetEXT()
1076 struct gl_vertex_array_object* vao; in _mesa_VertexArrayNormalOffsetEXT() local
1080 &vao, &vbo, in _mesa_VertexArrayNormalOffsetEXT()
1085 vao, vbo, in _mesa_VertexArrayNormalOffsetEXT()
1091 update_array(ctx, vao, vbo, in _mesa_VertexArrayNormalOffsetEXT()
1156 struct gl_vertex_array_object* vao; in _mesa_VertexArrayColorOffsetEXT() local
1160 &vao, &vbo, in _mesa_VertexArrayColorOffsetEXT()
1165 vao, vbo, in _mesa_VertexArrayColorOffsetEXT()
1171 update_array(ctx, vao, vbo, in _mesa_VertexArrayColorOffsetEXT()
1218 struct gl_vertex_array_object* vao; in _mesa_VertexArrayFogCoordOffsetEXT() local
1222 &vao, &vbo, in _mesa_VertexArrayFogCoordOffsetEXT()
1227 vao, vbo, in _mesa_VertexArrayFogCoordOffsetEXT()
1233 update_array(ctx, vao, vbo, in _mesa_VertexArrayFogCoordOffsetEXT()
1282 struct gl_vertex_array_object* vao; in _mesa_VertexArrayIndexOffsetEXT() local
1286 &vao, &vbo, in _mesa_VertexArrayIndexOffsetEXT()
1291 vao, vbo, in _mesa_VertexArrayIndexOffsetEXT()
1297 update_array(ctx, vao, vbo, in _mesa_VertexArrayIndexOffsetEXT()
1357 struct gl_vertex_array_object* vao; in _mesa_VertexArraySecondaryColorOffsetEXT() local
1361 &vao, &vbo, in _mesa_VertexArraySecondaryColorOffsetEXT()
1366 vao, vbo, in _mesa_VertexArraySecondaryColorOffsetEXT()
1372 update_array(ctx, vao, vbo, in _mesa_VertexArraySecondaryColorOffsetEXT()
1436 struct gl_vertex_array_object* vao; in _mesa_VertexArrayTexCoordOffsetEXT() local
1440 &vao, &vbo, in _mesa_VertexArrayTexCoordOffsetEXT()
1445 vao, vbo, in _mesa_VertexArrayTexCoordOffsetEXT()
1451 update_array(ctx, vao, vbo, in _mesa_VertexArrayTexCoordOffsetEXT()
1474 struct gl_vertex_array_object* vao; in _mesa_VertexArrayMultiTexCoordOffsetEXT() local
1478 &vao, &vbo, in _mesa_VertexArrayMultiTexCoordOffsetEXT()
1489 vao, vbo, in _mesa_VertexArrayMultiTexCoordOffsetEXT()
1495 update_array(ctx, vao, vbo, in _mesa_VertexArrayMultiTexCoordOffsetEXT()
1548 struct gl_vertex_array_object* vao; in _mesa_VertexArrayEdgeFlagOffsetEXT() local
1552 &vao, &vbo, in _mesa_VertexArrayEdgeFlagOffsetEXT()
1557 vao, vbo, in _mesa_VertexArrayEdgeFlagOffsetEXT()
1563 update_array(ctx, vao, vbo, in _mesa_VertexArrayEdgeFlagOffsetEXT()
1669 struct gl_vertex_array_object* vao; in _mesa_VertexArrayVertexAttribOffsetEXT() local
1673 &vao, &vbo, in _mesa_VertexArrayVertexAttribOffsetEXT()
1692 vao, vbo, in _mesa_VertexArrayVertexAttribOffsetEXT()
1698 update_array(ctx, vao, vbo, in _mesa_VertexArrayVertexAttribOffsetEXT()
1710 struct gl_vertex_array_object* vao; in _mesa_VertexArrayVertexAttribLOffsetEXT() local
1714 &vao, &vbo, in _mesa_VertexArrayVertexAttribLOffsetEXT()
1726 vao, vbo, in _mesa_VertexArrayVertexAttribLOffsetEXT()
1732 update_array(ctx, vao, vbo, in _mesa_VertexArrayVertexAttribLOffsetEXT()
1810 struct gl_vertex_array_object* vao; in _mesa_VertexArrayVertexAttribIOffsetEXT() local
1814 &vao, &vbo, in _mesa_VertexArrayVertexAttribIOffsetEXT()
1828 vao, vbo, in _mesa_VertexArrayVertexAttribIOffsetEXT()
1834 update_array(ctx, vao, vbo, in _mesa_VertexArrayVertexAttribIOffsetEXT()
1869 struct gl_vertex_array_object *vao, in _mesa_enable_vertex_array_attribs() argument
1873 assert(!vao->SharedAndImmutable); in _mesa_enable_vertex_array_attribs()
1876 attrib_bits &= ~vao->Enabled; in _mesa_enable_vertex_array_attribs()
1879 vao->Enabled |= attrib_bits; in _mesa_enable_vertex_array_attribs()
1880 vao->NewArrays |= attrib_bits; in _mesa_enable_vertex_array_attribs()
1884 update_attribute_map_mode(ctx, vao); in _mesa_enable_vertex_array_attribs()
1890 struct gl_vertex_array_object *vao, in enable_vertex_array_attrib() argument
1899 _mesa_enable_vertex_array_attrib(ctx, vao, VERT_ATTRIB_GENERIC(index)); in enable_vertex_array_attrib()
1925 struct gl_vertex_array_object *vao; in _mesa_EnableVertexArrayAttrib() local
1934 vao = _mesa_lookup_vao_err(ctx, vaobj, false, "glEnableVertexArrayAttrib"); in _mesa_EnableVertexArrayAttrib()
1935 if (!vao) in _mesa_EnableVertexArrayAttrib()
1938 enable_vertex_array_attrib(ctx, vao, index, "glEnableVertexArrayAttrib"); in _mesa_EnableVertexArrayAttrib()
1945 struct gl_vertex_array_object* vao = _mesa_lookup_vao_err(ctx, vaobj, in _mesa_EnableVertexArrayAttribEXT() local
1948 if (!vao) in _mesa_EnableVertexArrayAttribEXT()
1951 enable_vertex_array_attrib(ctx, vao, index, "glEnableVertexArrayAttribEXT"); in _mesa_EnableVertexArrayAttribEXT()
1959 struct gl_vertex_array_object *vao = _mesa_lookup_vao(ctx, vaobj); in _mesa_EnableVertexArrayAttrib_no_error() local
1960 _mesa_enable_vertex_array_attrib(ctx, vao, VERT_ATTRIB_GENERIC(index)); in _mesa_EnableVertexArrayAttrib_no_error()
1966 struct gl_vertex_array_object *vao, in _mesa_disable_vertex_array_attribs() argument
1970 assert(!vao->SharedAndImmutable); in _mesa_disable_vertex_array_attribs()
1973 attrib_bits &= vao->Enabled; in _mesa_disable_vertex_array_attribs()
1976 vao->Enabled &= ~attrib_bits; in _mesa_disable_vertex_array_attribs()
1977 vao->NewArrays |= attrib_bits; in _mesa_disable_vertex_array_attribs()
1981 update_attribute_map_mode(ctx, vao); in _mesa_disable_vertex_array_attribs()
2014 struct gl_vertex_array_object *vao; in _mesa_DisableVertexArrayAttrib() local
2023 vao = _mesa_lookup_vao_err(ctx, vaobj, false, "glDisableVertexArrayAttrib"); in _mesa_DisableVertexArrayAttrib()
2024 if (!vao) in _mesa_DisableVertexArrayAttrib()
2033 _mesa_disable_vertex_array_attrib(ctx, vao, attrib); in _mesa_DisableVertexArrayAttrib()
2040 struct gl_vertex_array_object* vao = _mesa_lookup_vao_err(ctx, vaobj, in _mesa_DisableVertexArrayAttribEXT() local
2043 if (!vao) in _mesa_DisableVertexArrayAttribEXT()
2052 _mesa_disable_vertex_array_attrib(ctx, vao, attrib); in _mesa_DisableVertexArrayAttribEXT()
2060 struct gl_vertex_array_object *vao = _mesa_lookup_vao(ctx, vaobj); in _mesa_DisableVertexArrayAttrib_no_error() local
2062 _mesa_disable_vertex_array_attrib(ctx, vao, attrib); in _mesa_DisableVertexArrayAttrib_no_error()
2073 const struct gl_vertex_array_object *vao, in get_vertex_array_attrib() argument
2085 assert(VERT_ATTRIB_GENERIC(index) < ARRAY_SIZE(vao->VertexAttrib)); in get_vertex_array_attrib()
2087 array = &vao->VertexAttrib[VERT_ATTRIB_GENERIC(index)]; in get_vertex_array_attrib()
2091 return !!(vao->Enabled & VERT_BIT_GENERIC(index)); in get_vertex_array_attrib()
2101 buf = vao->BufferBinding[array->BufferBindingIndex].BufferObj; in get_vertex_array_attrib()
2118 return vao->BufferBinding[array->BufferBindingIndex].InstanceDivisor; in get_vertex_array_attrib()
2343 struct gl_vertex_array_object *vao; in _mesa_GetVertexArrayIndexediv() local
2352 vao = _mesa_lookup_vao_err(ctx, vaobj, false, "glGetVertexArrayIndexediv"); in _mesa_GetVertexArrayIndexediv()
2353 if (!vao) in _mesa_GetVertexArrayIndexediv()
2383 params[0] = vao->BufferBinding[VERT_ATTRIB_GENERIC(index)].Offset; in _mesa_GetVertexArrayIndexediv()
2386 params[0] = vao->BufferBinding[VERT_ATTRIB_GENERIC(index)].Stride; in _mesa_GetVertexArrayIndexediv()
2389 params[0] = vao->BufferBinding[VERT_ATTRIB_GENERIC(index)].InstanceDivisor; in _mesa_GetVertexArrayIndexediv()
2392 buf = vao->BufferBinding[VERT_ATTRIB_GENERIC(index)].BufferObj; in _mesa_GetVertexArrayIndexediv()
2396 params[0] = get_vertex_array_attrib(ctx, vao, index, pname, in _mesa_GetVertexArrayIndexediv()
2408 struct gl_vertex_array_object *vao; in _mesa_GetVertexArrayIndexed64iv() local
2416 vao = _mesa_lookup_vao_err(ctx, vaobj, false, "glGetVertexArrayIndexed64iv"); in _mesa_GetVertexArrayIndexed64iv()
2417 if (!vao) in _mesa_GetVertexArrayIndexed64iv()
2452 params[0] = vao->BufferBinding[VERT_ATTRIB_GENERIC(index)].Offset; in _mesa_GetVertexArrayIndexed64iv()
2792 struct gl_vertex_array_object * const vao = ctx->Array.VAO; in _mesa_VertexAttribDivisor_no_error() local
2794 assert(genericIndex < ARRAY_SIZE(vao->VertexAttrib)); in _mesa_VertexAttribDivisor_no_error()
2807 _mesa_vertex_attrib_binding(ctx, vao, genericIndex, genericIndex); in _mesa_VertexAttribDivisor_no_error()
2808 vertex_binding_divisor(ctx, vao, genericIndex, divisor); in _mesa_VertexAttribDivisor_no_error()
2823 struct gl_vertex_array_object * const vao = ctx->Array.VAO; in _mesa_VertexAttribDivisor() local
2836 assert(genericIndex < ARRAY_SIZE(vao->VertexAttrib)); in _mesa_VertexAttribDivisor()
2849 _mesa_vertex_attrib_binding(ctx, vao, genericIndex, genericIndex); in _mesa_VertexAttribDivisor()
2850 vertex_binding_divisor(ctx, vao, genericIndex, divisor); in _mesa_VertexAttribDivisor()
2860 struct gl_vertex_array_object * vao; in _mesa_VertexArrayVertexAttribDivisorEXT() local
2867 vao = _mesa_lookup_vao_err(ctx, vaobj, in _mesa_VertexArrayVertexAttribDivisorEXT()
2870 if (!vao) in _mesa_VertexArrayVertexAttribDivisorEXT()
2884 assert(genericIndex < ARRAY_SIZE(vao->VertexAttrib)); in _mesa_VertexArrayVertexAttribDivisorEXT()
2897 _mesa_vertex_attrib_binding(ctx, vao, genericIndex, genericIndex); in _mesa_VertexArrayVertexAttribDivisorEXT()
2898 vertex_binding_divisor(ctx, vao, genericIndex, divisor); in _mesa_VertexArrayVertexAttribDivisorEXT()
2905 struct gl_vertex_array_object *vao, in vertex_array_vertex_buffer() argument
2911 vao->BufferBinding[VERT_ATTRIB_GENERIC(bindingIndex)].BufferObj; in vertex_array_vertex_buffer()
2943 _mesa_bind_vertex_buffer(ctx, vao, VERT_ATTRIB_GENERIC(bindingIndex), in vertex_array_vertex_buffer()
2953 struct gl_vertex_array_object *vao, in vertex_array_vertex_buffer_err() argument
2998 vertex_array_vertex_buffer(ctx, vao, bindingIndex, buffer, offset, in vertex_array_vertex_buffer_err()
3045 struct gl_vertex_array_object *vao = _mesa_lookup_vao(ctx, vaobj); in _mesa_VertexArrayVertexBuffer_no_error() local
3046 vertex_array_vertex_buffer(ctx, vao, bindingIndex, buffer, offset, in _mesa_VertexArrayVertexBuffer_no_error()
3056 struct gl_vertex_array_object *vao; in _mesa_VertexArrayVertexBuffer() local
3064 vao = _mesa_lookup_vao_err(ctx, vaobj, false, "glVertexArrayVertexBuffer"); in _mesa_VertexArrayVertexBuffer()
3065 if (!vao) in _mesa_VertexArrayVertexBuffer()
3068 vertex_array_vertex_buffer_err(ctx, vao, bindingIndex, buffer, offset, in _mesa_VertexArrayVertexBuffer()
3078 struct gl_vertex_array_object *vao; in _mesa_VertexArrayBindVertexBufferEXT() local
3079 vao = _mesa_lookup_vao_err(ctx, vaobj, true, "glVertexArrayBindVertexBufferEXT"); in _mesa_VertexArrayBindVertexBufferEXT()
3080 if (!vao) in _mesa_VertexArrayBindVertexBufferEXT()
3083 vertex_array_vertex_buffer_err(ctx, vao, bindingIndex, buffer, offset, in _mesa_VertexArrayBindVertexBufferEXT()
3090 struct gl_vertex_array_object *vao, in vertex_array_vertex_buffers() argument
3108 _mesa_bind_vertex_buffer(ctx, vao, VERT_ATTRIB_GENERIC(first + i), in vertex_array_vertex_buffers()
3169 &vao->BufferBinding[VERT_ATTRIB_GENERIC(first + i)]; in vertex_array_vertex_buffers()
3186 _mesa_bind_vertex_buffer(ctx, vao, VERT_ATTRIB_GENERIC(first + i), in vertex_array_vertex_buffers()
3196 struct gl_vertex_array_object *vao, in vertex_array_vertex_buffers_err() argument
3216 vertex_array_vertex_buffers(ctx, vao, first, count, buffers, offsets, in vertex_array_vertex_buffers_err()
3264 struct gl_vertex_array_object *vao = ctx->Array.VAO; in _mesa_InternalBindVertexBuffers() local
3271 _mesa_bind_vertex_buffer(ctx, vao, i, NULL, in _mesa_InternalBindVertexBuffers()
3273 vao->BufferBinding[i].Stride, false, false); in _mesa_InternalBindVertexBuffers()
3284 _mesa_bind_vertex_buffer(ctx, vao, i, buf, buffers[param_index].offset, in _mesa_InternalBindVertexBuffers()
3285 vao->BufferBinding[i].Stride, true, true); in _mesa_InternalBindVertexBuffers()
3299 struct gl_vertex_array_object *vao = _mesa_lookup_vao(ctx, vaobj); in _mesa_VertexArrayVertexBuffers_no_error() local
3300 vertex_array_vertex_buffers(ctx, vao, first, count, in _mesa_VertexArrayVertexBuffers_no_error()
3312 struct gl_vertex_array_object *vao; in _mesa_VertexArrayVertexBuffers() local
3320 vao = _mesa_lookup_vao_err(ctx, vaobj, false, "glVertexArrayVertexBuffers"); in _mesa_VertexArrayVertexBuffers()
3321 if (!vao) in _mesa_VertexArrayVertexBuffers()
3324 vertex_array_vertex_buffers_err(ctx, vao, first, count, in _mesa_VertexArrayVertexBuffers()
3431 struct gl_vertex_array_object *vao; in vertex_array_attrib_format() local
3438 vao = _mesa_lookup_vao(ctx, vaobj); in vertex_array_attrib_format()
3439 if (!vao) in vertex_array_attrib_format()
3442 vao = _mesa_lookup_vao_err(ctx, vaobj, isExtDsa, func); in vertex_array_attrib_format()
3443 if (!vao) in vertex_array_attrib_format()
3458 if (!validate_array_format(ctx, func, vao, in vertex_array_attrib_format()
3467 _mesa_update_array_format(ctx, vao, VERT_ATTRIB_GENERIC(attribIndex), size, in vertex_array_attrib_format()
3547 struct gl_vertex_array_object *vao, in vertex_array_attrib_binding() argument
3576 assert(VERT_ATTRIB_GENERIC(attribIndex) < ARRAY_SIZE(vao->VertexAttrib)); in vertex_array_attrib_binding()
3578 _mesa_vertex_attrib_binding(ctx, vao, in vertex_array_attrib_binding()
3623 struct gl_vertex_array_object *vao = _mesa_lookup_vao(ctx, vaobj); in _mesa_VertexArrayAttribBinding_no_error() local
3624 _mesa_vertex_attrib_binding(ctx, vao, in _mesa_VertexArrayAttribBinding_no_error()
3634 struct gl_vertex_array_object *vao; in _mesa_VertexArrayAttribBinding() local
3642 vao = _mesa_lookup_vao_err(ctx, vaobj, false, "glVertexArrayAttribBinding"); in _mesa_VertexArrayAttribBinding()
3643 if (!vao) in _mesa_VertexArrayAttribBinding()
3646 vertex_array_attrib_binding(ctx, vao, attribIndex, bindingIndex, in _mesa_VertexArrayAttribBinding()
3655 struct gl_vertex_array_object *vao; in _mesa_VertexArrayVertexAttribBindingEXT() local
3656 vao = _mesa_lookup_vao_err(ctx, vaobj, true, "glVertexArrayVertexAttribBindingEXT"); in _mesa_VertexArrayVertexAttribBindingEXT()
3657 if (!vao) in _mesa_VertexArrayVertexAttribBindingEXT()
3660 vertex_array_attrib_binding(ctx, vao, attribIndex, bindingIndex, in _mesa_VertexArrayVertexAttribBindingEXT()
3667 struct gl_vertex_array_object *vao, in vertex_array_binding_divisor() argument
3691 vertex_binding_divisor(ctx, vao, VERT_ATTRIB_GENERIC(bindingIndex), divisor); in vertex_array_binding_divisor()
3733 struct gl_vertex_array_object *vao = _mesa_lookup_vao(ctx, vaobj); in _mesa_VertexArrayBindingDivisor_no_error() local
3734 vertex_binding_divisor(ctx, vao, VERT_ATTRIB_GENERIC(bindingIndex), divisor); in _mesa_VertexArrayBindingDivisor_no_error()
3742 struct gl_vertex_array_object *vao; in _mesa_VertexArrayBindingDivisor() local
3751 vao = _mesa_lookup_vao_err(ctx, vaobj, false, "glVertexArrayBindingDivisor"); in _mesa_VertexArrayBindingDivisor()
3752 if (!vao) in _mesa_VertexArrayBindingDivisor()
3755 vertex_array_binding_divisor(ctx, vao, bindingIndex, divisor, in _mesa_VertexArrayBindingDivisor()
3764 struct gl_vertex_array_object *vao; in _mesa_VertexArrayVertexBindingDivisorEXT() local
3773 vao = _mesa_lookup_vao_err(ctx, vaobj, true, "glVertexArrayVertexBindingDivisorEXT"); in _mesa_VertexArrayVertexBindingDivisorEXT()
3774 if (!vao) in _mesa_VertexArrayVertexBindingDivisorEXT()
3777 vertex_array_binding_divisor(ctx, vao, bindingIndex, divisor, in _mesa_VertexArrayVertexBindingDivisorEXT()
3817 const struct gl_vertex_array_object *vao = ctx->Array.VAO; in _mesa_print_arrays() local
3819 fprintf(stderr, "Array Object %u\n", vao->Name); in _mesa_print_arrays()
3821 GLbitfield mask = vao->Enabled; in _mesa_print_arrays()
3824 const struct gl_array_attributes *array = &vao->VertexAttrib[i]; in _mesa_print_arrays()
3827 &vao->BufferBinding[array->BufferBindingIndex]; in _mesa_print_arrays()
3849 struct gl_vertex_array_object *vao, in init_array() argument
3852 assert(index < ARRAY_SIZE(vao->VertexAttrib)); in init_array()
3853 struct gl_array_attributes *array = &vao->VertexAttrib[index]; in init_array()
3854 assert(index < ARRAY_SIZE(vao->BufferBinding)); in init_array()
3855 struct gl_vertex_buffer_binding *binding = &vao->BufferBinding[index]; in init_array()
3875 struct gl_vertex_array_object *vao = &ctx->Array.DefaultVAOState; in init_default_vao_state() local
3877 vao->RefCount = 1; in init_default_vao_state()
3878 vao->SharedAndImmutable = false; in init_default_vao_state()
3881 for (unsigned i = 0; i < ARRAY_SIZE(vao->VertexAttrib); i++) { in init_default_vao_state()
3884 init_array(ctx, vao, VERT_ATTRIB_NORMAL, 3, GL_FLOAT); in init_default_vao_state()
3887 init_array(ctx, vao, VERT_ATTRIB_COLOR1, 3, GL_FLOAT); in init_default_vao_state()
3890 init_array(ctx, vao, VERT_ATTRIB_FOG, 1, GL_FLOAT); in init_default_vao_state()
3893 init_array(ctx, vao, VERT_ATTRIB_COLOR_INDEX, 1, GL_FLOAT); in init_default_vao_state()
3896 init_array(ctx, vao, VERT_ATTRIB_EDGEFLAG, 1, GL_UNSIGNED_BYTE); in init_default_vao_state()
3899 init_array(ctx, vao, VERT_ATTRIB_POINT_SIZE, 1, GL_FLOAT); in init_default_vao_state()
3902 init_array(ctx, vao, i, 4, GL_FLOAT); in init_default_vao_state()
3907 vao->_AttributeMapMode = ATTRIBUTE_MAP_MODE_IDENTITY; in init_default_vao_state()
3934 struct gl_vertex_array_object *vao = (struct gl_vertex_array_object *) data; in delete_arrayobj_cb() local
3936 _mesa_delete_vao(ctx, vao); in delete_arrayobj_cb()
3954 struct gl_vertex_array_object* vao; in _mesa_GetVertexArrayIntegervEXT() local
3958 vao = _mesa_lookup_vao_err(ctx, vaobj, true, in _mesa_GetVertexArrayIntegervEXT()
3960 if (!vao) in _mesa_GetVertexArrayIntegervEXT()
3976 *param = vao->VertexAttrib[VERT_ATTRIB_POS].Format.Size; in _mesa_GetVertexArrayIntegervEXT()
3979 *param = vao->VertexAttrib[VERT_ATTRIB_POS].Format.Type; in _mesa_GetVertexArrayIntegervEXT()
3982 *param = vao->VertexAttrib[VERT_ATTRIB_POS].Stride; in _mesa_GetVertexArrayIntegervEXT()
3985 buf = vao->BufferBinding[VERT_ATTRIB_POS].BufferObj; in _mesa_GetVertexArrayIntegervEXT()
3989 *param = vao->VertexAttrib[VERT_ATTRIB_COLOR0].Format.Size; in _mesa_GetVertexArrayIntegervEXT()
3992 *param = vao->VertexAttrib[VERT_ATTRIB_COLOR0].Format.Type; in _mesa_GetVertexArrayIntegervEXT()
3995 *param = vao->VertexAttrib[VERT_ATTRIB_COLOR0].Stride; in _mesa_GetVertexArrayIntegervEXT()
3998 buf = vao->BufferBinding[VERT_ATTRIB_COLOR0].BufferObj; in _mesa_GetVertexArrayIntegervEXT()
4002 *param = vao->VertexAttrib[VERT_ATTRIB_EDGEFLAG].Stride; in _mesa_GetVertexArrayIntegervEXT()
4005 buf = vao->BufferBinding[VERT_ATTRIB_EDGEFLAG].BufferObj; in _mesa_GetVertexArrayIntegervEXT()
4009 *param = vao->VertexAttrib[VERT_ATTRIB_COLOR_INDEX].Format.Type; in _mesa_GetVertexArrayIntegervEXT()
4012 *param = vao->VertexAttrib[VERT_ATTRIB_COLOR_INDEX].Stride; in _mesa_GetVertexArrayIntegervEXT()
4015 buf = vao->BufferBinding[VERT_ATTRIB_COLOR_INDEX].BufferObj; in _mesa_GetVertexArrayIntegervEXT()
4019 *param = vao->VertexAttrib[VERT_ATTRIB_NORMAL].Format.Type; in _mesa_GetVertexArrayIntegervEXT()
4022 *param = vao->VertexAttrib[VERT_ATTRIB_NORMAL].Stride; in _mesa_GetVertexArrayIntegervEXT()
4025 buf = vao->BufferBinding[VERT_ATTRIB_NORMAL].BufferObj; in _mesa_GetVertexArrayIntegervEXT()
4029 *param = vao->VertexAttrib[VERT_ATTRIB_TEX(ctx->Array.ActiveTexture)].Format.Size; in _mesa_GetVertexArrayIntegervEXT()
4032 *param = vao->VertexAttrib[VERT_ATTRIB_TEX(ctx->Array.ActiveTexture)].Format.Type; in _mesa_GetVertexArrayIntegervEXT()
4035 *param = vao->VertexAttrib[VERT_ATTRIB_TEX(ctx->Array.ActiveTexture)].Stride; in _mesa_GetVertexArrayIntegervEXT()
4038 buf = vao->BufferBinding[VERT_ATTRIB_TEX(ctx->Array.ActiveTexture)].BufferObj; in _mesa_GetVertexArrayIntegervEXT()
4042 *param = vao->VertexAttrib[VERT_ATTRIB_FOG].Format.Type; in _mesa_GetVertexArrayIntegervEXT()
4045 *param = vao->VertexAttrib[VERT_ATTRIB_FOG].Stride; in _mesa_GetVertexArrayIntegervEXT()
4048 buf = vao->BufferBinding[VERT_ATTRIB_FOG].BufferObj; in _mesa_GetVertexArrayIntegervEXT()
4052 *param = vao->VertexAttrib[VERT_ATTRIB_COLOR1].Format.Size; in _mesa_GetVertexArrayIntegervEXT()
4055 *param = vao->VertexAttrib[VERT_ATTRIB_COLOR1].Format.Type; in _mesa_GetVertexArrayIntegervEXT()
4058 *param = vao->VertexAttrib[VERT_ATTRIB_COLOR1].Stride; in _mesa_GetVertexArrayIntegervEXT()
4061 buf = vao->BufferBinding[VERT_ATTRIB_COLOR1].BufferObj; in _mesa_GetVertexArrayIntegervEXT()
4067 *param = !!(vao->Enabled & VERT_BIT_POS); in _mesa_GetVertexArrayIntegervEXT()
4070 *param = !!(vao->Enabled & VERT_BIT_COLOR0); in _mesa_GetVertexArrayIntegervEXT()
4073 *param = !!(vao->Enabled & VERT_BIT_EDGEFLAG); in _mesa_GetVertexArrayIntegervEXT()
4076 *param = !!(vao->Enabled & VERT_BIT_COLOR_INDEX); in _mesa_GetVertexArrayIntegervEXT()
4079 *param = !!(vao->Enabled & VERT_BIT_NORMAL); in _mesa_GetVertexArrayIntegervEXT()
4082 *param = !!(vao->Enabled & VERT_BIT_TEX(ctx->Array.ActiveTexture)); in _mesa_GetVertexArrayIntegervEXT()
4085 *param = !!(vao->Enabled & VERT_BIT_FOG); in _mesa_GetVertexArrayIntegervEXT()
4088 *param = !!(vao->Enabled & VERT_BIT_COLOR1); in _mesa_GetVertexArrayIntegervEXT()
4100 _get_vao_pointerv(pname, vao, &ptr, "glGetVertexArrayIntegervEXT"); in _mesa_GetVertexArrayIntegervEXT()
4113 struct gl_vertex_array_object* vao; in _mesa_GetVertexArrayPointervEXT() local
4115 vao = _mesa_lookup_vao_err(ctx, vaobj, true, in _mesa_GetVertexArrayPointervEXT()
4117 if (!vao) in _mesa_GetVertexArrayPointervEXT()
4142 _get_vao_pointerv(pname, vao, param, "glGetVertexArrayPointervEXT"); in _mesa_GetVertexArrayPointervEXT()
4149 struct gl_vertex_array_object* vao; in _mesa_GetVertexArrayIntegeri_vEXT() local
4152 vao = _mesa_lookup_vao_err(ctx, vaobj, true, in _mesa_GetVertexArrayIntegeri_vEXT()
4154 if (!vao) in _mesa_GetVertexArrayIntegeri_vEXT()
4170 *param = !!(vao->Enabled & VERT_BIT_TEX(index)); in _mesa_GetVertexArrayIntegeri_vEXT()
4173 *param = vao->VertexAttrib[VERT_ATTRIB_TEX(index)].Format.Size; in _mesa_GetVertexArrayIntegeri_vEXT()
4176 *param = vao->VertexAttrib[VERT_ATTRIB_TEX(index)].Format.Type; in _mesa_GetVertexArrayIntegeri_vEXT()
4179 *param = vao->VertexAttrib[VERT_ATTRIB_TEX(index)].Stride; in _mesa_GetVertexArrayIntegeri_vEXT()
4182 buf = vao->BufferBinding[VERT_ATTRIB_TEX(index)].BufferObj; in _mesa_GetVertexArrayIntegeri_vEXT()
4186 *param = get_vertex_array_attrib(ctx, vao, index, pname, "glGetVertexArrayIntegeri_vEXT"); in _mesa_GetVertexArrayIntegeri_vEXT()
4194 struct gl_vertex_array_object* vao; in _mesa_GetVertexArrayPointeri_vEXT() local
4196 vao = _mesa_lookup_vao_err(ctx, vaobj, true, in _mesa_GetVertexArrayPointeri_vEXT()
4198 if (!vao) in _mesa_GetVertexArrayPointeri_vEXT()
4214 *param = (GLvoid *) vao->VertexAttrib[VERT_ATTRIB_GENERIC(index)].Ptr; in _mesa_GetVertexArrayPointeri_vEXT()
4217 *param = (GLvoid *) vao->VertexAttrib[VERT_ATTRIB_TEX(index)].Ptr; in _mesa_GetVertexArrayPointeri_vEXT()