MeshLib Python Docs
Loading...
Searching...
No Matches
mrmeshpy.MeshBuilder Class Reference

Classes

class  BuildSettings
 
class  equalVector3f
 
class  MeshPiece
 
class  Triangle
 
class  VertDuplication
 
class  VertexIdentifier
 
class  VertSpan
 

Static Public Member Functions

None addTriangles (MeshTopology res, Triangulation t, MeshBuilder.BuildSettings settings='{}')
 
None addTriangles (MeshTopology res, std_vector_Id_VertTag vertTriples, FaceBitSet createdFaces=None)
 
int duplicateNonManifoldVertices (Triangulation t, FaceBitSet region=None, std_vector_MeshBuilder_VertDuplication dups=None)
 
MeshTopology fromDisjointMeshPieces (Triangulation t, VertId maxVertId, std_vector_MeshBuilder_MeshPiece pieces, MeshBuilder.BuildSettings settings='{}')
 
MeshTopology fromFaceSoup (std_vector_Id_VertTag verts, Vector_MeshBuilder_VertSpan_FaceId faces, MeshBuilder.BuildSettings settings='{}', func_bool_from_float progressCb='{}')
 
Mesh fromPointTriples (std_vector_std_array_Vector3_float_3 posTriples)
 
MeshTopology fromTriangles (Triangulation t, MeshBuilder.BuildSettings settings='{}', func_bool_from_float progressCb='{}')
 
MeshTopology fromTrianglesDuplicatingNonManifoldVertices (Triangulation t, std_vector_MeshBuilder_VertDuplication dups=None, MeshBuilder.BuildSettings settings='{}')
 
int uniteCloseVertices (Mesh mesh, float closeDist, bool uniteOnlyBd=True, VertMap optionalVertOldToNew=None)
 

Static Protected Member Functions

 _pybind11_conduit_v1_ (*args, **kwargs)
 

Detailed Description

This is a namespace.

Member Function Documentation

◆ _pybind11_conduit_v1_()

mrmeshpy.MeshBuilder._pybind11_conduit_v1_ ( * args,
** kwargs )
staticprotected

◆ addTriangles() [1/2]

None mrmeshpy.MeshBuilder.addTriangles ( MeshTopology res,
std_vector_Id_VertTag vertTriples,
FaceBitSet createdFaces = None )
static
adds triangles in the existing topology, auto selecting face ids for them;
vertTriples on output contain the remaining triangles that could not be added into the topology right now, but may be added later when other triangles appear in the mesh

◆ addTriangles() [2/2]

None mrmeshpy.MeshBuilder.addTriangles ( MeshTopology res,
Triangulation t,
MeshBuilder.BuildSettings settings = '{}' )
static
adds triangles in the existing topology, given face indecies must be free;
settings.region on output contain the remaining triangles that could not be added into the topology right now, but may be added later when other triangles appear in the mesh

◆ duplicateNonManifoldVertices()

int mrmeshpy.MeshBuilder.duplicateNonManifoldVertices ( Triangulation t,
FaceBitSet region = None,
std_vector_MeshBuilder_VertDuplication dups = None )
static
resolve non-manifold vertices by creating duplicate vertices in the triangulation (which is modified)
return number of duplicated vertices

◆ fromDisjointMeshPieces()

MeshTopology mrmeshpy.MeshBuilder.fromDisjointMeshPieces ( Triangulation t,
VertId maxVertId,
std_vector_MeshBuilder_MeshPiece pieces,
MeshBuilder.BuildSettings settings = '{}' )
static
construct mesh topology in parallel from given disjoint mesh pieces (which do not have any shared vertex)
and some additional triangles (in settings) that join the pieces

◆ fromFaceSoup()

MeshTopology mrmeshpy.MeshBuilder.fromFaceSoup ( std_vector_Id_VertTag verts,
Vector_MeshBuilder_VertSpan_FaceId faces,
MeshBuilder.BuildSettings settings = '{}',
func_bool_from_float progressCb = '{}' )
static
construct mesh topology from face soup, where each face can have arbitrary degree (not only triangles)

◆ fromPointTriples()

Mesh mrmeshpy.MeshBuilder.fromPointTriples ( std_vector_std_array_Vector3_float_3 posTriples)
static
construct mesh from point triples;
all coinciding points are given the same VertId in the result

◆ fromTriangles()

MeshTopology mrmeshpy.MeshBuilder.fromTriangles ( Triangulation t,
MeshBuilder.BuildSettings settings = '{}',
func_bool_from_float progressCb = '{}' )
static
construct mesh topology from a set of triangles with given ids;
if skippedTris is given then it receives all input triangles not added in the resulting topology

◆ fromTrianglesDuplicatingNonManifoldVertices()

MeshTopology mrmeshpy.MeshBuilder.fromTrianglesDuplicatingNonManifoldVertices ( Triangulation t,
std_vector_MeshBuilder_VertDuplication dups = None,
MeshBuilder.BuildSettings settings = '{}' )
static
construct mesh topology from a set of triangles with given ids;
unlike simple fromTriangles() it tries to resolve non-manifold vertices by creating duplicate vertices;
triangulation is modified to introduce duplicates

◆ uniteCloseVertices()

int mrmeshpy.MeshBuilder.uniteCloseVertices ( Mesh mesh,
float closeDist,
bool uniteOnlyBd = True,
VertMap optionalVertOldToNew = None )
static
the function finds groups of mesh vertices located closer to each other than \\param closeDist, and unites such vertices in one;
then the mesh is rebuilt from the remaining triangles
\\param optionalVertOldToNew is the mapping of vertices: before -> after
\\param uniteOnlyBd if true then only boundary vertices can be united, all internal vertices (even close ones) will remain
\\return the number of vertices united, 0 means no change in the mesh

The documentation for this class was generated from the following file: