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

Method test_tiled

python/pymesh/wires/tests/test_inflator.py:23–39  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

21 self.assertTrue(mesh.is_closed())
22
23 def test_tiled(self):
24 wire_network = self.get_brick5()
25 params = Parameters(wire_network, 0.1)
26 tiler = Tiler()
27 tiler.set_base_pattern(wire_network)
28 tiler.tile_with_guide_bbox(
29 np.zeros(3), np.ones(3), np.ones(3)*2, params)
30 tiled_wire_network = tiler.wire_network
31
32 inflator = Inflator(tiled_wire_network)
33 inflator.inflate(
34 tiled_wire_network.get_attribute("thickness").ravel())
35 mesh = inflator.mesh
36
37 self.assertLess(0, mesh.num_vertices)
38 self.assertLess(0, mesh.num_faces)
39 self.assertTrue(mesh.is_closed())
40
41 def test_periodic(self):
42 wire_network = self.get_pattern1065()

Callers

nothing calls this directly

Calls 9

set_base_patternMethod · 0.95
tile_with_guide_bboxMethod · 0.95
inflateMethod · 0.95
ParametersClass · 0.90
TilerClass · 0.90
InflatorClass · 0.90
get_brick5Method · 0.80
get_attributeMethod · 0.45
is_closedMethod · 0.45

Tested by

no test coverage detected