natiny_mesh_set_dynamic
void natiny_mesh_set_dynamic(NatinyMesh mesh, bool dynamic);
Selects the mesh upload path.
Parameters
| Name | Type | Description |
|---|---|---|
mesh |
NatinyMesh |
Mesh handle |
dynamic |
bool |
true to transform on the CPU every frame |
Example
natiny_mesh_set_dynamic(mesh, true);
Notes
- A static mesh - the default - is uploaded once into buffers of its own and drawn from there, one draw call per part.
- A dynamic mesh is transformed on the CPU into the shared batch every frame. Parts are batched per texture.
- The setting belongs to the mesh and therefore affects every model that shares it.