From 99cc92d2be7b8b50d0285bda829c1cf9587ff1d2 Mon Sep 17 00:00:00 2001 From: hm-thinkbook14p Date: Sat, 31 Oct 2026 20:38:29 +0800 Subject: [PATCH] perf(tools): skip diagnosis for orient-only runs --- tools/vde_brep_check.cpp | 23 ++++++++++++++--------- 1 file changed, 14 insertions(+), 9 deletions(-) diff --git a/tools/vde_brep_check.cpp b/tools/vde_brep_check.cpp index b053d5aa8..b0af4179d 100644 --- a/tools/vde_brep_check.cpp +++ b/tools/vde_brep_check.cpp @@ -392,6 +392,20 @@ int main(int argc, char** argv) { if (shells.size() > 16) std::printf(" ... %zu more shells\n", shells.size() - 16); const auto v0 = validate(body); + if (orient) { + try { + const auto rep = fix_shell_orientation_strict(body); + std::printf(" orient: flipped=%d ok=%d\n", rep.flipped_faces, rep.ok ? 1 : 0); + } catch (const std::exception& e) { + std::printf(" orient exception: %s\n", e.what()); + } + const auto vo = validate(body); + print_validation("orient", vo); + if (!deep && !heal && !pinch) { + if (!(vo.valid && vo.watertightness > 0.99)) ++bad; + continue; + } + } print_validation("raw", v0); print_diag(diagnose_body(body)); if (deep) { @@ -411,15 +425,6 @@ int main(int argc, char** argv) { } const bool body_bad = !(v0.valid && v0.watertightness > 0.99); if (body_bad) ++bad; - if (orient) { - try { - const auto rep = fix_shell_orientation_strict(body); - std::printf(" orient: flipped=%d ok=%d\n", rep.flipped_faces, rep.ok ? 1 : 0); - } catch (const std::exception& e) { - std::printf(" orient exception: %s\n", e.what()); - } - print_validation("orient", validate(body)); - } if (pinch && !heal) { int n = 0; try {