Ejemplo n.º 1
0
 def test_crossing_3d_boxes(self):
     # bboxes do overlap, but do not contain corner points of the other bbox
     bbox1 = BoundingBox([(0, 1, 0), (3, 2, 1)])
     bbox2 = BoundingBox([(1, 0, 0), (2, 3, 1)])
     assert bbox1.intersect(bbox2) is True
Ejemplo n.º 2
0
 def test_do_not_intersect_empty(self):
     bbox = BoundingBox([(0, 0, 0), (3, 3, 3)])
     empty = BoundingBox()
     assert bbox.intersect(empty) is False
     assert empty.intersect(bbox) is False
     assert empty.intersect(empty) is False