From df0abb710e4b941b1664c66250d1539ac0fef73a Mon Sep 17 00:00:00 2001 From: Arseny Kapoulkine Date: Mon, 21 Oct 2024 19:26:26 -0700 Subject: [PATCH] demo: Adjust "not full" calculation for uniform meshlets This might be a little misleading in the future, but uniform meshlets can almost never reach full vertex utilization as the triangle count should be reached first on regular meshes. So for now it would be more useful to count meshlets that don't exhaust the triangle limit even though this makes the metric differ between two types. --- demo/main.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/demo/main.cpp b/demo/main.cpp index 2d299e68..6a0aad2f 100644 --- a/demo/main.cpp +++ b/demo/main.cpp @@ -992,7 +992,7 @@ void meshlets(const Mesh& mesh, bool scan = false, bool uniform = false) avg_vertices += m.vertex_count; avg_triangles += m.triangle_count; - not_full += m.vertex_count < max_vertices; + not_full += uniform ? m.triangle_count < max_triangles : m.vertex_count < max_vertices; for (unsigned int j = 0; j < m.vertex_count; ++j) if (boundary[meshlet_vertices[m.vertex_offset + j]] > 1)