This commit is contained in:
2023-11-15 23:13:22 -06:00
parent d8bc1d0fe3
commit 04dbead9a2
19 changed files with 330 additions and 25 deletions

View File

@ -22,7 +22,7 @@ void Mesh::createBuffers(
this->indiceCount = indiceCount;
auto sizePos = sizeof(glm::vec3) * verticeCount;
auto sizeInds = sizeof(meshindice_t) * indiceCount;
auto sizeInds = sizeof(int32_t) * indiceCount;
auto sizeCoords = sizeof(glm::vec2) * verticeCount;
// Generate vertex array, I don't think I need to do this tbh.
@ -160,8 +160,8 @@ void Mesh::bufferIndices(
assertNoGLError();
glBufferSubData(
GL_ELEMENT_ARRAY_BUFFER,
sizeof(meshindice_t) * pos,
sizeof(meshindice_t) * len,
sizeof(int32_t) * pos,
sizeof(int32_t) * len,
(void*)indices
);
assertNoGLError();