Now supporting multiple material per mesh. Simon changed glDrawElementsBaseVertex to glDrawElements in DrawFinalPass.cpp Hallelulijah!
This commit is contained in:
@@ -56,9 +56,7 @@ void DrawFinalPass::Draw(RenderScene& scene)
|
||||
|
||||
glBindVertexArray(modelJob->Model->VAO);
|
||||
glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, modelJob->Model->ElementBuffer);
|
||||
glDrawElementsBaseVertex(GL_TRIANGLES, modelJob->EndIndex - modelJob->StartIndex + 1, GL_UNSIGNED_INT, 0, modelJob->StartIndex);
|
||||
|
||||
continue;
|
||||
glDrawElements(GL_TRIANGLES, modelJob->EndIndex - modelJob->StartIndex + 1, GL_UNSIGNED_INT, (void*)(modelJob->StartIndex * sizeof(unsigned int)));
|
||||
}
|
||||
}
|
||||
GLERROR("DrawFinalPass::Draw: END");
|
||||
|
||||
Reference in New Issue
Block a user