mirror of
https://github.com/JoeyDeVries/LearnOpenGL.git
synced 2026-01-02 04:37:54 +08:00
Instancing glDrawElements argument fix.
This commit is contained in:
@@ -182,7 +182,7 @@ int main()
|
||||
for(GLuint i = 0; i < rock.meshes.size(); i++)
|
||||
{
|
||||
glBindVertexArray(rock.meshes[i].VAO);
|
||||
glDrawElementsInstanced(GL_TRIANGLES, rock.meshes[i].vertices.size(), GL_UNSIGNED_INT, 0, amount);
|
||||
glDrawElementsInstanced(GL_TRIANGLES, rock.meshes[i].indices.size(), GL_UNSIGNED_INT, 0, amount);
|
||||
glBindVertexArray(0);
|
||||
}
|
||||
// reset our texture binding
|
||||
|
||||
Reference in New Issue
Block a user