← All demos

Instanced rendering

Every blade below is one instance of a single triangle, drawn in one draw call. The attribute layout — including per-instance divisor attributes — is recorded once in a VertexArray, and the shared rotation/tint parameters stream through a std140 UniformBuffer every frame.

1 draw call — 1,440 instances
Instancing — layout recorded once, parameters streamed per frame via UniformBuffer.update() VertexArray · UniformBuffer
1,440
0.50
1.05

Moving the instance-count slider re-uploads the per-instance buffer with GLBuffer.upload() — the recorded VertexArray keeps pointing at the same buffer object, so nothing else changes. API reference: VertexArray and UniformBuffer.