MCPcopy Create free account
hub / github.com/PyMesh/PyMesh / test_multiple_components

Method test_multiple_components

python/pymesh/tests/test_outerhull.py:67–80  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

65 interior_mesh.bbox)
66
67 def test_multiple_components(self):
68 mesh_1 = generate_box_mesh(
69 np.array([0, 0, 0]), np.array([1, 1, 1]))
70 mesh_2 = generate_box_mesh(
71 np.array([2, 2, 2]), np.array([3, 3, 3]))
72
73 mesh = merge_meshes((mesh_1, mesh_2))
74 outer_hulls = compute_outer_hull(mesh, all_layers=True)
75 self.assertEqual(1, len(outer_hulls))
76 outer_hull = outer_hulls[0]
77
78 self.assertTrue(outer_hull.is_closed())
79 self.assertEqual(2, outer_hull.num_components)
80 self.assert_valid_attributes(mesh, outer_hull)
81
82 def test_face_face_touch(self):
83 mesh_1 = generate_box_mesh(

Callers

nothing calls this directly

Calls 5

generate_box_meshFunction · 0.90
merge_meshesFunction · 0.90
compute_outer_hullFunction · 0.90
is_closedMethod · 0.45

Tested by

no test coverage detected