summaryrefslogtreecommitdiffstats
path: root/src/egl
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2011-10-21 10:09:48 -0600
committerBrian Paul <[email protected]>2011-10-21 10:09:48 -0600
commit6b72eded19398f9599d76ebd4cbaec52fc7a252d (patch)
treeec77e682ce13368065ba1d6066e521ec8d53cbe7 /src/egl
parent1595c79d9c60d8cc03763e64285b691d6748be95 (diff)
st/mesa: fix a bug in and re-org setup_interleaved_attribs()
We were mis-computing the size of the user-space vertex buffer in some circumstances. This led to a failed assertion at u_inlines.h:222 when using the VMware svga driver. For example, if we had arrays such as: array[0]: element_offset = 12, stride = 24 array[1]: element_offset = 0, stride = 24 We'd mistakenly compute 'bytes' to be 12 bytes too small. I've reorganized the function too. By time it's called, we know that we've got interleaved arrays either all in one VBO or all in user memory and the stride is equal for all arrays. Move the code that lived inside the attr==0 test after the loop. In the loop we compute the true vertex size. That size factors into the pipe->redefine_user_buffer() call later. Using the vertex size instead of array[0]'s element_offset fixes the failed assertion. Reviewed-by: José Fonseca <[email protected]>
Diffstat (limited to 'src/egl')
0 files changed, 0 insertions, 0 deletions