Initial work on unified graphics buffers representing different types of data.

This commit is contained in:
Alex Szpakowski
2020-01-12 16:41:23 -04:00
parent 23bc1a7aae
commit b0232a4a6b
14 changed files with 219 additions and 92 deletions
+1 -1
View File
@@ -173,7 +173,7 @@ void Graphics::createQuadIndexBuffer()
return;
size_t size = sizeof(uint16) * (LOVE_UINT16_MAX / 4) * 6;
quadIndexBuffer = newBuffer(size, nullptr, BUFFER_INDEX, vertex::USAGE_STATIC, 0);
quadIndexBuffer = newBuffer(size, nullptr, BUFFERFLAG_INDEX, vertex::USAGE_STATIC, 0);
Buffer::Mapper map(*quadIndexBuffer);
vertex::fillIndices(vertex::TriangleIndexMode::QUADS, 0, LOVE_UINT16_MAX, (uint16 *) map.get());