Meshlet culling example
Meshlet culling example
We recommend that you first read the Meshlets topic.
The Meshlet culling example topic presents the pseudocode of an Amplification Shader implementation of a technique called meshlet culling. Since a meshlet’s primitives ideally conform to spatial and orientational coherence, we can store efficient culling data per-meshlet. This can be used to quickly cull a meshlet list against a view in an Amplification Shader and only dispatch Mesh Shader instances for those surviving meshlets.
The technique starts with an Amplification Shader where each thread processes a single meshlet. This means that we must dispatch ceil(MeshletCount / GROUP_SIZE) threadgroups on the command list.
Each Amplification Shader threadgroup is then responsible for processing GROUP_SIZE meshlets. Each thread culls its meshlet against the view frustum, determines its export slot, and then writes its index to the payload data. It then uses DispatchMesh to dispatch one Mesh Shader threadgroup for each surviving meshlet to render. Each Mesh Shader threadgroup then loads its meshlet from the payload data and exports its geometry.
The full sample can be found on the XBOX Developer Downloads page.
Last modified on August 20, 2026
