Fixed issue #200.

This commit is contained in:
Branimir Karadžić 2014-12-06 18:12:40 -08:00
parent 69469388a0
commit 1a5dae9862

View file

@ -4879,6 +4879,14 @@ namespace bgfx
bx::HashMurmur2A murmur; bx::HashMurmur2A murmur;
murmur.begin(); murmur.begin();
murmur.add(draw.m_vertexBuffer.idx); murmur.add(draw.m_vertexBuffer.idx);
if (isValid(draw.m_vertexBuffer) )
{
const VertexBufferGL& vb = m_vertexBuffers[draw.m_vertexBuffer.idx];
uint16_t decl = !isValid(vb.m_decl) ? draw.m_vertexDecl.idx : vb.m_decl.idx;
murmur.add(decl);
}
murmur.add(draw.m_indexBuffer.idx); murmur.add(draw.m_indexBuffer.idx);
murmur.add(draw.m_instanceDataBuffer.idx); murmur.add(draw.m_instanceDataBuffer.idx);
murmur.add(draw.m_instanceDataOffset); murmur.add(draw.m_instanceDataOffset);