pyopensn.mesh.SurfaceMesh
- class pyopensn.mesh.SurfaceMesh
Surface mesh.
Wrapper of
opensn::SurfaceMesh
.- ImportFromMshFiles(self: pyopensn.mesh.SurfaceMesh, file_name: str, as_poly: bool) int
Loads a surface mesh from gmsh’s file format.
- Parameters:
file_name (str) – Surface mesh filename.
as_poly (bool) – Indicate if the surface mesh is allowed to contain polygonal facets (as opposed to only triangular faces).
- ImportFromOBJFile(self: pyopensn.mesh.SurfaceMesh, file_name: str, as_poly: bool = False, transform: pyopensn.math.Vector3 = Vector3(0, 0, 0)) int
Loads a surface mesh from a wavefront .obj file.
- Parameters:
file_name (str) – Surface mesh filename.
as_poly (bool, default=False) – Indicate if the surface mesh is allowed to contain polygonal facets (as opposed to only triangular faces).
translation (pyopensn.math.Vector3, default=(0.0, 0.0, 0.0)) – Translation to perform on the mesh.
- ImportFromTriangleFiles(self: pyopensn.mesh.SurfaceMesh, file_name: str, as_poly: bool) int
Loads a surface mesh from triangle’s file format.
- Parameters:
file_name (str) – Surface mesh filename.
as_poly (bool) – Indicate if the surface mesh is allowed to contain polygonal facets (as opposed to only triangular faces).
- __init__(self: pyopensn.mesh.SurfaceMesh, **kwargs) None
Construct a surface mesh.
This function does not take any arguments.