We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent aef27d8 commit dfb9985Copy full SHA for dfb9985
tests/test_all.py
@@ -600,3 +600,24 @@ def udf_sphere(Q):
600
unique_ijk, J, unique_corners = igl.unique_sparse_voxel_corners(origin,h0,max_depth,ijk)
601
unique_S = sdf_sphere(unique_corners)
602
V,F = igl.marching_cubes(unique_S,unique_corners,J,0.0)
603
+
604
605
+def test_boundary_conditions():
606
+ V, F, T = single_tet()
607
+ C = V[[0, 1, 2]]
608
+ P = np.array([0, 1, 2], dtype=int)
609
+ BE = np.array([[0, 1]], dtype=int)
610
+ CE = np.array([[0, 1], [1, 2], [2, 0]], dtype=int)
611
+ CF = np.array([[0, 1, 2]], dtype=int)
612
613
+ b1, bc1 = igl.boundary_conditions(V, F, C, P, BE, CE, CF)
614
+ assert b1.shape[0] == bc1.shape[0]
615
+ assert bc1.shape[1] == P.shape[0] + BE.shape[0]
616
617
+ b2, bc2 = igl.boundary_conditions(V, F, C, P)
618
+ assert b2.shape[0] == bc2.shape[0]
619
+ assert bc2.shape[1] == P.shape[0]
620
621
+ b3, bc3 = igl.boundary_conditions(V, F, C, BE=BE)
622
+ assert b3.shape[0] == bc3.shape[0]
623
+ assert bc3.shape[1] == BE.shape[0]
0 commit comments