Function validate_mesh

Source
pub fn validate_mesh(mesh: &Mesh) -> Result<(), MeshError>
Expand description

Check source geometry without allocating, registering a mesh, or using a GPU. Checks every source vertex, including unused vertices and UVs. Zero normals, degenerate triangles, and UVs outside 0..1 remain valid. This checks the individual static-mesh budget, not currently available registry capacity.

use ferravex_render::{mesh::Mesh3d, retained::validate_mesh, Vec3, WHITE};
let mesh = Mesh3d::cuboid(Vec3::ONE, WHITE).mesh;
validate_mesh(&mesh)?;