feat(v3.6): SSI-based boolean operations — face-face intersection splitting
CI / Build & Test (push) Failing after 1m40s
CI / Release Build (push) Failing after 31s
Build & Test / build-and-test (push) Has been cancelled
Build & Test / python-bindings (push) Has been cancelled

This commit is contained in:
茂之钳
2026-07-24 14:36:32 +00:00
parent 00ea90b522
commit 38ebb963d0
2 changed files with 281 additions and 32 deletions
+36
View File
@@ -176,6 +176,42 @@ TEST(BrepBooleanTest, Intersection_Commutative) {
EXPECT_TRUE(r2.is_valid());
}
// ═══════════════════════════════════════════════════════════
// SSI-based boolean operations (v3.6)
// ═══════════════════════════════════════════════════════════
TEST(BrepBooleanTest, Union_BoxAndSphere_UsesSSI) {
auto box = make_box(3, 3, 3);
auto sphere = make_sphere(1.5);
auto result = brep_union(box, sphere);
EXPECT_TRUE(result.is_valid());
// SSI creates more fragments than simple box faces
if (result.num_faces() > 0) {
EXPECT_GT(result.num_faces(), 0u);
}
}
TEST(BrepBooleanTest, Union_CylinderAndBox_UsesSSI) {
auto box = make_box(4, 4, 4);
auto cyl = make_cylinder(1.5, 6.0);
auto result = brep_union(box, cyl);
EXPECT_TRUE(result.is_valid());
}
TEST(BrepBooleanTest, Intersection_BoxAndSphere_UsesSSI) {
auto box = make_box(3, 3, 3);
auto sphere = make_sphere(1.5);
auto result = brep_intersection(box, sphere);
EXPECT_TRUE(result.is_valid());
}
TEST(BrepBooleanTest, Difference_BoxAndCylinder_UsesSSI) {
auto box = make_box(4, 4, 4);
auto cyl = make_cylinder(1.0, 6.0);
auto result = brep_difference(box, cyl);
EXPECT_TRUE(result.is_valid());
}
// ═══════════════════════════════════════════════════════════
// Performance (v3.5)
// ═══════════════════════════════════════════════════════════