IT lexicon › Programming › Indexed rendering

Indexed rendering

Programming På svenska → Updated: 2026-10-25

Vertices are stored once in a vertex buffer and reused through a separate list of indices, instead of being duplicated per triangle.

A cube has eight corners but twelve triangles sharing them. Without indices each triangle carries its own three vertices — thirty-six copies. Indexed rendering stores the eight unique vertices once plus a list of indices into them, cutting both memory and the vertex-shader work the GPU can cache.

The post-transform vertex cache rewards index orders that revisit recently used vertices, which is exactly what vertex-cache optimisation and triangle strips exploit. glDrawElements/DrawIndexed is the indexed path; the alternative, glDrawArrays, re-lists every vertex. Standard since the fixed-function era.

← Back to the lexicon