Skip to content

Commit

Permalink
simplify: Fix TRACE output of resulting triangle count
Browse files Browse the repository at this point in the history
Everywhere else the debug output seems correct but here we forgot to
convert from index count to triangle count.
  • Loading branch information
zeux committed Nov 3, 2023
1 parent c21d3be commit 0efc961
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/simplifier.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1611,7 +1611,7 @@ size_t meshopt_simplifyEdge(unsigned int* destination, const unsigned int* indic
}

#if TRACE
printf("result: %d triangles, error: %e; total %d passes\n", int(result_count), sqrtf(result_error), int(pass_count));
printf("result: %d triangles, error: %e; total %d passes\n", int(result_count / 3), sqrtf(result_error), int(pass_count));
#endif

#ifndef NDEBUG
Expand Down

0 comments on commit 0efc961

Please sign in to comment.