-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Labels
Description
Using instanced rendering (especially for recangles), it's can reduce the buffer data size quite a bit. The glVertexAttribDivisor allows for reusing data shared across all the vertices of each rectangle (instance).
Note: I have later found sources stating that the overhead from instancing is not worth it when rendering sprites
https://www.khronos.org/registry/OpenGL-Refpages/gl4/html/glVertexAttribDivisor.xhtml
SO post on indexed + instanced rendering:
https://stackoverflow.com/questions/31398169/how-attribute-divisor-works-with-indexed-drawing