Me149 — isInnerPoint_closest_is_triangle: ray hits triangle interior, sign(normal.x) determines inside/outside

§12.14 mesh defects (sub-class: isInnerPoint / closest-is-triangle interior)

topology

Sources

Description

A closed watertight wedge (4 lateral faces + 2 base triangles, all 9 edges interior). When the closest ray-crossing point is strictly interior to a triangle, isInnerPoint returns the sign of that triangle's normal X-component. The mesh is fully closed: every edge is shared by exactly 2 triangles, confirming no boundary exists.

Reproducer recipe

v0=(0,0,0), v1=(2,0,0), v2=(2,0,1), v3=(0,0,1), v4=(1,2,0.5); 6 triangles forming a closed wedge.

Expected kernel behavior

query at centroid hits a triangle interior; Branch 18 fires, return sign(getVector().x).

Expected validation

Live oracle output

No live oracle data — run _run_corpus to populate.

Fixture content

Show fixture bytes
1{
2  "vertices": [
3    [
4      0.0,
5      0.0,
6      0.0
7    ],
8    [
9      2.0,
10      0.0,
11      0.0
12    ],
13    [
14      2.0,
15      0.0,
16      1.0
17    ],
18    [
19      0.0,
20      0.0,
21      1.0
22    ],
23    [
24      1.0,
25      2.0,
26      0.5
27    ]
28  ],
29  "triangles": [
30    [
31      0,
32      1,
33      4
34    ],
35    [
36      1,
37      2,
38      4
39    ],
40    [
41      2,
42      3,
43      4
44    ],
45    [
46      3,
47      0,
48      4
49    ],
50    [
51      0,
52      3,
53      2
54    ],
55    [
56      0,
57      2,
58      1
59    ]
60  ],
61  "metadata": {
62    "id": "Me149",
63    "schema_version": 0,
64    "defect_class": "isInnerPoint_closest_is_triangle",
65    "title": "isInnerPoint_closest_is_triangle: ray hits triangle interior, return sign(normal.x) determines inside/outside",
66    "assertions": [
67      {
68        "kind": "edge_shared_by_n_triangles",
69        "edge": [
70          0,
71          1
72        ],
73        "n": 2
74      },
75      {
76        "kind": "edge_shared_by_n_triangles",
77        "edge": [
78          1,
79          2
80        ],
81        "n": 2
82      },
83      {
84        "kind": "edge_shared_by_n_triangles",
85        "edge": [
86          2,
87          3
88        ],
89        "n": 2
90      },
91      {
92        "kind": "edge_shared_by_n_triangles",
93        "edge": [
94          0,
95          3
96        ],
97        "n": 2
98      },
99      {
100        "kind": "edge_shared_by_n_triangles",
101        "edge": [
102          0,
103          4
104        ],
105        "n": 2
106      },
107      {
108        "kind": "edge_shared_by_n_triangles",
109        "edge": [
110          1,
111          4
112        ],
113        "n": 2
114      },
115      {
116        "kind": "edge_shared_by_n_triangles",
117        "edge": [
118          2,
119          4
120        ],
121        "n": 2
122      },
123      {
124        "kind": "edge_shared_by_n_triangles",
125        "edge": [
126          3,
127          4
128        ],
129        "n": 2
130      },
131      {
132        "kind": "edge_shared_by_n_triangles",
133        "edge": [
134          0,
135          2
136        ],
137        "n": 2
138      },
139      {
140        "kind": "edge_shared_by_n_triangles",
141        "edge": [
142          1,
143          3
144        ],
145        "n": 0
146      }
147    ]
148  }
149}