mesh-examples/12-14-mesh/Me274.mesh.json
Sources
- CGAL PMP `autorefine_impl::autorefine_triangle_soup` Branch 5 (*case 2*: `case 2:` when nbi==2 and !on_same_edge → segments.emplace_back @ line 1136)
- `MESH_HEAL_COVERAGE.md`.
Description
Two triangles arranged in an X-shape: t0 is horizontal and t1 is tilted so that two of its edges pierce t0's face, creating a proper crossing segment (nbi==2). Since the intersection segment does not lie on a shared edge (on_same_edge is false), Branch 5 records the crossing via segments.emplace_back.
Reproducer recipe
t0 horizontal plane; t1 tilted to cross t0 in two points; assert triangles_self_intersect([0,1]); all edges n=1.
Expected kernel behavior
Branch 5 fires; case 2 with !on_same_edge; segments.emplace_back records the intersection segment; both insertion points added to each triangle.
Expected validation
Live oracle output
No live oracle data — run _run_corpus to populate.
Fixture content
Show fixture bytes
1{ 2 "vertices": [ 3 [ 4 -1.0, 5 -1.0, 6 0.0 7 ], 8 [ 9 1.0, 10 -1.0, 11 0.0 12 ], 13 [ 14 0.0, 15 1.0, 16 0.0 17 ], 18 [ 19 -0.5, 20 0.0, 21 -1.0 22 ], 23 [ 24 0.5, 25 0.0, 26 -1.0 27 ], 28 [ 29 0.0, 30 0.0, 31 1.0 32 ] 33 ], 34 "triangles": [ 35 [ 36 0, 37 1, 38 2 39 ], 40 [ 41 3, 42 4, 43 5 44 ] 45 ], 46 "metadata": { 47 "id": "Me274", 48 "schema_version": 0, 49 "defect_class": "autorefine_segment_intersection", 50 "title": "autorefine_triangle_soup segment-intersection two-point branch: case 2 segment SI", 51 "assertions": [ 52 { 53 "kind": "triangles_self_intersect", 54 "triangles": [ 55 0, 56 1 57 ] 58 }, 59 { 60 "kind": "edge_shared_by_n_triangles", 61 "edge": [ 62 0, 63 1 64 ], 65 "n": 1 66 }, 67 { 68 "kind": "edge_shared_by_n_triangles", 69 "edge": [ 70 1, 71 2 72 ], 73 "n": 1 74 }, 75 { 76 "kind": "edge_shared_by_n_triangles", 77 "edge": [ 78 0, 79 2 80 ], 81 "n": 1 82 }, 83 { 84 "kind": "edge_shared_by_n_triangles", 85 "edge": [ 86 3, 87 4 88 ], 89 "n": 1 90 }, 91 { 92 "kind": "edge_shared_by_n_triangles", 93 "edge": [ 94 4, 95 5 96 ], 97 "n": 1 98 }, 99 { 100 "kind": "edge_shared_by_n_triangles", 101 "edge": [ 102 3, 103 5 104 ], 105 "n": 1 106 } 107 ] 108 } 109}