Namespaces | Functions
Foam::triSurfaceChecks Namespace Reference

Namespaces

 connectionOps
 
 manifoldOps
 
 orientationOps
 
 selectorOps
 

Functions

label checkAngles (const triSurf &surf, labelLongList &badTriangles, const scalar angleTol)
 
label checkAngles (triSurf &surf, const word subsetName, const scalar angleTol)
 
label checkSurfaceManifolds (const triSurf &, labelLongList &triangleInManifold)
 check for existence of boudary and non-manifold edges More...
 
label checkSurfaceManifolds (triSurf &surf, const word subsetPrefix)
 
label checkForHoles (const triSurf &, labelLongList &)
 check for existence of holes in the surface mesh More...
 
label checkForHoles (triSurf &surf, const word subsetName)
 
label checkForNonManifoldEdges (const triSurf &, labelLongList &)
 check for existence of non-manifold edges More...
 
label checkForNonManifoldEdges (triSurf &surf, const word subsetPrefix)
 
label checkOrientation (const triSurf &, labelLongList &triangleInGroup)
 check orientation of triangles More...
 
label checkOrientation (triSurf &surf, const word subsetPrefix)
 
label checkDisconnectedParts (const triSurf &, labelLongList &triangleInRegion)
 check for disconnected surface parts More...
 
label checkDisconnectedParts (triSurf &surf, const word subsetPrefix)
 
void calculateBoundingBox (const triSurf &, boundBox &)
 calculate bounding box of the surface mesh More...
 
label checkCollocatedPoints (const triSurf &, labelLongList &, const scalar distTol=1e-6)
 check existence of collocated points More...
 
label checkCollocatedPoints (triSurf &surf, const word subsetName, const scalar distTol)
 
label checkSelfIntersections (const triSurf &, labelLongList &, const scalar tol=1e-6)
 check if there exist any self-intersections More...
 
label checkSelfIntersections (triSurf &surf, const word subsetName, const scalar tol)
 
label checkOverlaps (const triSurf &, labelLongList &, const scalar tol=1e-6, const scalar angleTol=5.0)
 check if there exist any overlaps More...
 
label checkOverlaps (triSurf &surf, const word subsetName, const scalar tol, const scalar angleTol)
 

Function Documentation

◆ checkAngles() [1/2]

label checkAngles ( const triSurf ,
labelLongList ,
const scalar  angleTol = 5.0 
)

check the angles of triangles. Triangles wth the smallest angle below the given threshold are marked as bad-quality triangles

Definition at line 58 of file triSurfaceChecks.C.

References LongList< T, Offset >::append(), LongList< T, Offset >::clear(), Foam::cos(), FixedList::fcIndex(), forAll, Foam::mag(), triSurfPoints::points(), and LongList< T, Offset >::size().

Referenced by checkAngles(), and main().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ checkAngles() [2/2]

label checkAngles ( triSurf surf,
const word  subsetName,
const scalar  angleTol 
)

◆ checkSurfaceManifolds() [1/2]

label checkSurfaceManifolds ( const triSurf surf,
labelLongList triangleInManifold 
)

check for existence of boudary and non-manifold edges

Definition at line 225 of file triSurfaceChecks.C.

References triSurfAddressing::edgeFacets(), triSurfAddressing::facetEdges(), and Foam::help::groupMarking().

Referenced by checkSurfaceManifolds(), and main().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ checkSurfaceManifolds() [2/2]

label checkSurfaceManifolds ( triSurf surf,
const word  subsetPrefix 
)

◆ checkForHoles() [1/2]

label checkForHoles ( const triSurf surf,
labelLongList badTriangles 
)

check for existence of holes in the surface mesh

Definition at line 274 of file triSurfaceChecks.C.

References LongList< T, Offset >::append(), LongList< T, Offset >::clear(), triSurfAddressing::edgeFacets(), forAll, LongList< T, Offset >::size(), and VRWGraph::sizeOfRow().

Referenced by checkForHoles(), checkForNonManifoldEdges(), and main().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ checkForHoles() [2/2]

label checkForHoles ( triSurf surf,
const word  subsetName 
)

◆ checkForNonManifoldEdges() [1/2]

label checkForNonManifoldEdges ( const triSurf surf,
labelLongList badTriangles 
)

check for existence of non-manifold edges

Definition at line 315 of file triSurfaceChecks.C.

References LongList< T, Offset >::append(), LongList< T, Offset >::clear(), triSurfAddressing::edgeFacets(), forAll, forAllRow, LongList< T, Offset >::size(), and VRWGraph::sizeOfRow().

Referenced by main().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ checkForNonManifoldEdges() [2/2]

label checkForNonManifoldEdges ( triSurf surf,
const word  subsetPrefix 
)

◆ checkOrientation() [1/2]

label checkOrientation ( const triSurf surf,
labelLongList triangleInGroup 
)

check orientation of triangles

Definition at line 460 of file triSurfaceChecks.C.

References triSurfAddressing::edgeFacets(), triSurfAddressing::facetEdges(), triSurfFacets::facets(), Foam::help::groupMarking(), LongList< T, Offset >::setSize(), and triSurfFacets::size().

Referenced by checkOrientation(), and triSurfaceClassifyEdges::triSurfaceClassifyEdges().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ checkOrientation() [2/2]

label checkOrientation ( triSurf surf,
const word  subsetPrefix 
)

◆ checkDisconnectedParts() [1/2]

label checkDisconnectedParts ( const triSurf surf,
labelLongList triangleInRegion 
)

check for disconnected surface parts

Definition at line 582 of file triSurfaceChecks.C.

References triSurfAddressing::edgeFacets(), triSurfAddressing::facetEdges(), Foam::help::groupMarking(), LongList< T, Offset >::setSize(), and triSurfFacets::size().

Referenced by checkDisconnectedParts(), and main().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ checkDisconnectedParts() [2/2]

label checkDisconnectedParts ( triSurf surf,
const word  subsetPrefix 
)

◆ calculateBoundingBox()

void calculateBoundingBox ( const triSurf surf,
boundBox bb 
)

calculate bounding box of the surface mesh

Definition at line 631 of file triSurfaceChecks.C.

References boundBox::max(), Foam::max(), boundBox::min(), Foam::min(), and triSurfPoints::points().

Referenced by main().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ checkCollocatedPoints() [1/2]

label checkCollocatedPoints ( const triSurf surf,
labelLongList collocatedPoints,
const scalar  distTol 
)

◆ checkCollocatedPoints() [2/2]

label checkCollocatedPoints ( triSurf surf,
const word  subsetName,
const scalar  distTol 
)

◆ checkSelfIntersections() [1/2]

label checkSelfIntersections ( const triSurf surf,
labelLongList badFaces,
const scalar  tol 
)

check if there exist any self-intersections

triangles share an edge and cannot self-intersect

check if the opposite edge intersects the triangle

triangles do not share any vertices

Definition at line 727 of file triSurfaceChecks.C.

References LongList< T, Offset >::append(), DynList< T, staticSize >::append(), LongList< T, Offset >::clear(), meshOctree::containedTriangles(), meshOctreeCreator::createOctreeWithRefinedBoundary(), Foam::help::doTrianglesIntersect(), Foam::e, meshOctree::findLeavesContainedInBox(), forAll, intersect(), boundBox::max(), Foam::max(), boundBox::min(), Foam::min(), triSurfPoints::points(), s(), Foam::help::scalarToText(), triSurfFacets::size(), LongList< T, Offset >::size(), DynList< T, staticSize >::size(), and Foam::help::triLineIntersection().

Referenced by checkSelfIntersections(), and main().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ checkSelfIntersections() [2/2]

label checkSelfIntersections ( triSurf surf,
const word  subsetName,
const scalar  tol 
)

◆ checkOverlaps() [1/2]

label checkOverlaps ( const triSurf surf,
labelLongList badFaces,
const scalar  tol,
const scalar  angleTol 
)

◆ checkOverlaps() [2/2]

label checkOverlaps ( triSurf surf,
const word  subsetName,
const scalar  tol,
const scalar  angleTol 
)