|
Monad Engine da02fba2
> Undercity Codex_
|
Describes the memory layout of a single vertex in a VBO. More...
Include dependency graph for VertexLayout.h:
This graph shows which files directly or indirectly include this file:Go to the source code of this file.
Classes | |
| struct | mnd::VertexElement |
| Describes one interleaved vertex attribute within a VBO. More... | |
| struct | mnd::VertexLayout |
| Complete description of how vertex data is packed in a VBO. More... | |
Namespaces | |
| namespace | mnd |
Describes the memory layout of a single vertex in a VBO.
A VertexLayout is a list of VertexElements — each element maps one interleaved field (position, UV, normal …) to a numbered shader attribute.
The layout is created by Builder factory methods together with the vertex data and is then stored inside Mesh. When Mesh::Bind() is called, GraphicsAPI reads the layout to issue the matching glVertexAttribPointer calls, connecting the raw buffer bytes to the GLSL attribute slots.
Example interleaved vertex (pos + normal + UV) looks like:
Definition in file VertexLayout.h.