diff options
author | Mathias Fröhlich <[email protected]> | 2018-11-17 07:13:11 +0100 |
---|---|---|
committer | Mathias Fröhlich <[email protected]> | 2018-11-21 06:27:19 +0100 |
commit | a4c01839c27a683901ef22e23e02e5849520222b (patch) | |
tree | 83a9bef75abf955cf6f7e43932cd78962bf45702 /src/mesa | |
parent | 182ed6de8c18543682029585b1a69491791e55d4 (diff) |
nouveau: Use gl_array_attribute::_ElementSize.
Instead of open coding the size computation, use the
already available gl_array_attribute::_ElementSize value.
Reviewed-by: Brian Paul <[email protected]>
Reviewed-by: Marek Olšák <[email protected]>
Signed-off-by: Mathias Fröhlich <[email protected]>
Diffstat (limited to 'src/mesa')
-rw-r--r-- | src/mesa/drivers/dri/nouveau/nouveau_vbo_t.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mesa/drivers/dri/nouveau/nouveau_vbo_t.c b/src/mesa/drivers/dri/nouveau/nouveau_vbo_t.c index 3900c770cbe..97ff07808b9 100644 --- a/src/mesa/drivers/dri/nouveau/nouveau_vbo_t.c +++ b/src/mesa/drivers/dri/nouveau/nouveau_vbo_t.c @@ -49,7 +49,7 @@ get_array_stride(struct gl_context *ctx, const struct tnl_vertex_array *a) if (render->mode == VBO && !_mesa_is_bufferobj(binding->BufferObj)) { const struct gl_array_attributes *attrib = a->VertexAttrib; /* Pack client buffers. */ - return align(_mesa_sizeof_type(attrib->Type) * attrib->Size, 4); + return align(attrib->_ElementSize, 4); } else { return binding->Stride; } |