Topology counts weld coincident vertices and edges, and merge two pieces of one surface only across an edge that just those two share: tangent holes touching along a line keep the wall cut at the pinch, the same way at every pinch (oracle 42 passes; 75/76)
Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01AS5Tn3xieewUSg3uxrMVdL
This commit is contained in:
1 parent
51ffaf9945
commit
109b8acbb5
2 files changed
+52
-18
No files matched your search
@@ -1261,3 +1261,18 @@ fn smooth_loft_through_three_sections() {
|
||||
let v = measure(&c).unwrap().volume;
|
||||
assert!(v > PI * 64.0 * 30.0 && v < 576.0 * 30.0, "{v}");
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn tangent_holes_pinch_alike() {
|
||||
// Holes at ±15 and ±25 touch along a line (x = ±20); ±30 overlaps ±25. The ±25 wall is cut
|
||||
// in two at the pinch, the same way on both sides (as Fusion counts it).
|
||||
let mut b = box_solid(Vec3::new(-50.0, -20.0, 0.0), Vec3::new(50.0, 20.0, 5.0)).unwrap();
|
||||
for x in [15.0, 25.0, 30.0, -15.0, -25.0, -30.0] {
|
||||
let plane = Plane::XY.offset(-1.0);
|
||||
let disc = Region2 { outer: Loop2::circle(Vec2::new(x, 0.0), 5.0), holes: vec![] };
|
||||
let t = extrude(&plane, &[disc], 0.0, 7.0).unwrap().pop().unwrap();
|
||||
b = boolean(&b, &t, BoolOp::Cut).unwrap().unwrap();
|
||||
}
|
||||
let m = measure(&b).unwrap();
|
||||
assert_eq!(m.merged.faces, 14, "{:?}", m.merged);
|
||||
}
|
||||
Reference in new issue
Block a user