From 11db1346e05059d59438da720a049ff50b2c3826 Mon Sep 17 00:00:00 2001 From: Andreas Kloeckner Date: Thu, 2 May 2024 10:35:41 -0500 Subject: [PATCH] mesh.io.from_vertices_and_simplices: use new force_positive_orientation --- meshmode/mesh/io.py | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/meshmode/mesh/io.py b/meshmode/mesh/io.py index 84c0c863..2dbe618f 100644 --- a/meshmode/mesh/io.py +++ b/meshmode/mesh/io.py @@ -399,18 +399,10 @@ def from_vertices_and_simplices( grp = make_group_from_vertices(vertices, simplices, order) - if fix_orientation: - if grp.dim != vertices.shape[0]: - raise ValueError("can only fix orientation of volume meshes") - - from meshmode.mesh.processing import ( - find_volume_mesh_element_group_orientation, flip_element_group) - orient = find_volume_mesh_element_group_orientation(vertices, grp) - grp = flip_element_group(vertices, grp, orient < 0) - return make_mesh( vertices=vertices, groups=[grp], - is_conforming=True) + is_conforming=True, + force_positive_orientation=fix_orientation) # }}}