2 from test_case
import TestCase
10 pts = hppfcl.StdVec_Vec3f()
11 pts.append(np.array((0, 0, 0)))
12 pts.append(np.array((0, 1, 0)))
13 pts.append(np.array((1, 0, 0)))
14 pts.append(np.array((0, 0, 1)))
15 tri = hppfcl.StdVec_Triangle()
16 tri.append(hppfcl.Triangle(0, 1, 2))
17 tri.append(hppfcl.Triangle(0, 1, 3))
18 tri.append(hppfcl.Triangle(0, 2, 3))
19 tri.append(hppfcl.Triangle(1, 2, 3))
20 return hppfcl.Convex(pts, tri)
25 with open(
"save.p",
"wb")
as f:
27 with open(
"save.p",
"rb")
as f:
30 self.assertTrue(obj == obj2)
33 box = hppfcl.Box(1.0, 2.0, 3.0)
36 sphere = hppfcl.Sphere(1.0)
39 ellipsoid = hppfcl.Ellipsoid(1.0, 2.0, 3.0)
45 capsule = hppfcl.Capsule(1.0, 2.0)
48 cylinder = hppfcl.Cylinder(1.0, 2.0)
51 plane = hppfcl.Plane(np.array([0.0, 0.0, 1.0]), 2.0)
54 half_space = hppfcl.Halfspace(np.array([0.0, 0.0, 1.0]), 2.0)
58 if __name__ ==
"__main__":