Skip to content

MeshPass

MeshPass is a CPU-side collection pass that runs before geometry rasterization. It traverses the scene, gathers visible mesh entities, builds draw command lists, and writes them into shared logical buffers consumed by downstream passes such as GeometryPass and DebugPass.

Render Graph Role

AttributeValue
GroupGeometry
Reads-
Writesmesh_context, mesh_collector_storage
CullableNo (non-cullable)

MeshPass is marked non-cullable because its output buffers have no single downstream consumer - multiple passes read from them, and culling would silently break the pipeline.

mesh_context

mesh_context is a logical buffer containing the resolved per-entity draw state:

  • Resolved Model handle
  • Resolved Shader handle
  • TransformComponent world matrix
  • MaterialComponent snapshot

mesh_collector_storage

mesh_collector_storage holds auxiliary per-draw data such as bounding volumes and instance indices, used by DebugPass and PostProcessPass for screen-space effects and culling feedback.

Visibility Culling

MeshPass performs frustum culling against the active camera before submitting entities to the buffers. Entities outside the view frustum are excluded and will not appear in downstream draw calls.