The find_best_vertex_split function iterates over all vertices:
|
for (index, vertex) in vertices.iter().enumerate() { |
However, immediately after the loop, there is an assertion that best_split_index may not be the last vertex:
|
assert!(best_split_index < vertices.len() - 1); |
While testing file sizes of different formats, I've encountered a model that apparently meets this edge case, resulting in an assertion error.
This is the mesh I am trying to export. It's the dragon sample model from the official glTF samples with computed tangents, run through meshopt: dragon.zip