Points connected by edges. More...
Public Member Functions | |
TypeName ("edgeMesh") | |
Runtime type information. More... | |
edgeMesh () | |
Construct null. More... | |
edgeMesh (const pointField &, const edgeList &) | |
Construct from components. More... | |
edgeMesh (pointField &&, edgeList &&) | |
Construct by transferring components (points, edges). More... | |
edgeMesh (const edgeMesh &) | |
Copy constructor. More... | |
edgeMesh (edgeMesh &&) | |
Move constructor. More... | |
edgeMesh (const fileName &) | |
Construct from file name (uses extension to determine type) More... | |
edgeMesh (const fileName &, const word &ext) | |
Construct from file name (uses extension to determine type) More... | |
edgeMesh (Istream &) | |
Construct from Istream. More... | |
declareRunTimeSelectionTable (autoPtr, edgeMesh, fileExtension,(const fileName &name),(name)) | |
virtual | ~edgeMesh () |
Destructor. More... | |
declareMemberFunctionSelectionTable (void, edgeMesh, write, fileExtension,(const fileName &name, const edgeMesh &mesh),(name, mesh)) | |
void | transfer (edgeMesh &) |
Transfer the contents of the argument and annul the argument. More... | |
bool | read (const fileName &, const word &ext) |
Read from file. Chooses reader based on explicit extension. More... | |
virtual bool | read (const fileName &) |
Read from file. Chooses reader based on detected extension. More... | |
const pointField & | points () const |
Return points. More... | |
const edgeList & | edges () const |
Return edges. More... | |
const labelListList & | pointEdges () const |
Return edges. More... | |
label | regions (labelList &edgeRegion) const |
Find connected regions. Set region number per edge. More... | |
virtual void | clear () |
Clear all storage. More... | |
virtual void | reset (pointField &&points, edgeList &&edges) |
Reset primitive data (points, edges) More... | |
virtual void | scalePoints (const scalar) |
Scale points. A non-positive factor is ignored. More... | |
virtual void | mergePoints (const scalar mergeDist, labelList &) |
Merge common points (points within mergeDist). Return map from. More... | |
virtual void | mergeEdges () |
Merge duplicate edges. More... | |
virtual void | writeStats (Ostream &) const |
virtual void | write (const fileName &name) const |
Generic write routine. Chooses writer based on extension. More... | |
void | operator= (const edgeMesh &) |
void | operator= (edgeMesh &&) |
Public Member Functions inherited from edgeMeshFormatsCore | |
edgeMeshFormatsCore () | |
Construct null. More... | |
virtual | ~edgeMeshFormatsCore () |
Destructor. More... | |
Static Public Member Functions | |
static bool | canRead (const fileName &, const bool verbose=false) |
Can we read this file format? More... | |
static bool | canReadType (const word &ext, const bool verbose=false) |
Can we read this file format? More... | |
static bool | canWriteType (const word &ext, const bool verbose=false) |
Can we write this file format type? More... | |
static wordHashSet | readTypes () |
static wordHashSet | writeTypes () |
static autoPtr< edgeMesh > | New (const fileName &, const word &ext) |
Select constructed from filename (explicit extension) More... | |
static autoPtr< edgeMesh > | New (const fileName &) |
Select constructed from filename (implicit extension) More... | |
static void | write (const fileName &, const edgeMesh &) |
Write to file. More... | |
Static Public Member Functions inherited from edgeMeshFormatsCore | |
static bool | checkSupport (const wordHashSet &available, const word &ext, const bool verbose, const word &functionName) |
Protected Member Functions | |
pointField & | storedPoints () |
Non-const access to global points. More... | |
edgeList & | storedEdges () |
Non-const access to the edges. More... | |
Friends | |
Ostream & | operator<< (Ostream &, const edgeMesh &) |
Istream & | operator>> (Istream &, edgeMesh &) |
Additional Inherited Members | |
Static Public Attributes inherited from edgeMeshFormatsCore | |
static word | nativeExt |
The file extension corresponding to 'native' edge format. More... | |
Static Protected Member Functions inherited from edgeMeshFormatsCore | |
static string | getLineNoComment (IFstream &) |
Read non-comment line. More... | |
Points connected by edges.
Can be read from fileName based on extension. Uses New factory method to select the reader and transfer the result.
Definition at line 69 of file edgeMesh.H.
edgeMesh | ( | ) |
Construct null.
Definition at line 123 of file edgeMesh.C.
Referenced by edgeMesh::edgeMesh().
edgeMesh | ( | const pointField & | points, |
const edgeList & | edges | ||
) |
Construct from components.
Definition at line 133 of file edgeMesh.C.
References edgeMesh::edgeMesh().
edgeMesh | ( | pointField && | pointLst, |
edgeList && | edgeLst | ||
) |
Construct by transferring components (points, edges).
Definition at line 146 of file edgeMesh.C.
Copy constructor.
Definition at line 42 of file edgeMeshI.H.
Move constructor.
Definition at line 51 of file edgeMeshI.H.
Construct from file name (uses extension to determine type)
Definition at line 46 of file edgeMeshIO.C.
References edgeMesh::read().
Construct from file name (uses extension to determine type)
Definition at line 33 of file edgeMeshIO.C.
References Foam::blockMeshTools::read().
|
virtual |
Destructor.
Definition at line 160 of file edgeMesh.C.
|
inlineprotected |
Non-const access to global points.
Definition at line 28 of file edgeMeshI.H.
Referenced by OBJedgeFormat::read(), and STARCDedgeFormat::read().
|
inlineprotected |
Non-const access to the edges.
Definition at line 34 of file edgeMeshI.H.
Referenced by OBJedgeFormat::read(), and STARCDedgeFormat::read().
TypeName | ( | "edgeMesh" | ) |
Runtime type information.
|
static |
Can we read this file format?
Definition at line 90 of file edgeMesh.C.
References Foam::abort(), fileName::ext(), Foam::FatalError, FatalErrorInFunction, Foam::invertManyToMany(), fileName::lessExt(), and List< T >::size().
Referenced by edgeMesh::canWriteType().
|
static |
Can we read this file format?
Definition at line 58 of file edgeMesh.C.
References edgeMesh::canWriteType().
Referenced by edgeMesh::writeTypes().
|
static |
Can we write this file format type?
Definition at line 74 of file edgeMesh.C.
References edgeMesh::canRead().
Referenced by edgeMesh::canReadType().
|
static |
Definition at line 43 of file edgeMesh.C.
|
static |
Definition at line 49 of file edgeMesh.C.
References edgeMesh::canReadType().
declareRunTimeSelectionTable | ( | autoPtr | , |
edgeMesh | , | ||
fileExtension | , | ||
(const fileName &name) | , | ||
(name) | |||
) |
|
static |
Select constructed from filename (explicit extension)
Definition at line 31 of file edgeMeshNew.C.
References Foam::exit(), Foam::FatalError, FatalErrorInFunction, Foam::name(), and Foam::nl.
Referenced by edgeMesh::New(), and edgeMesh::read().
|
static |
Select constructed from filename (implicit extension)
Definition at line 53 of file edgeMeshNew.C.
References fileName::ext(), fileName::lessExt(), and edgeMesh::New().
declareMemberFunctionSelectionTable | ( | void | , |
edgeMesh | , | ||
write | , | ||
fileExtension | , | ||
(const fileName &name, const edgeMesh &mesh) | , | ||
(name, mesh) | |||
) |
Write to file.
Definition at line 87 of file edgeMeshIO.C.
References Foam::endl(), Foam::exit(), fileName::ext(), Foam::FatalError, FatalErrorInFunction, InfoInFunction, mesh, Foam::name(), and Foam::nl.
Referenced by edgeMesh::read(), edgeMesh::write(), and extendedEdgeMesh::writeObj().
void transfer | ( | edgeMesh & | mesh | ) |
Transfer the contents of the argument and annul the argument.
Definition at line 197 of file edgeMesh.C.
References List< T >::transfer().
Referenced by edgeMesh::read(), and extendedEdgeMesh::transfer().
Read from file. Chooses reader based on explicit extension.
Definition at line 75 of file edgeMeshIO.C.
References edgeMesh::New(), edgeMesh::transfer(), and edgeMesh::write().
Referenced by edgeMesh::edgeMesh(), and edgeMesh::read().
|
virtual |
Read from file. Chooses reader based on detected extension.
Reimplemented in extendedEdgeMesh, STARCDedgeFormat, edgeMeshFormat, VTKedgeFormat, OBJedgeFormat, extendedFeatureEdgeMeshFormat, NASedgeFormat, and extendedEdgeMeshFormat.
Definition at line 58 of file edgeMeshIO.C.
References fileName::ext(), fileName::lessExt(), and edgeMesh::read().
|
inline |
Return points.
Definition at line 62 of file edgeMeshI.H.
Referenced by extendedEdgeMesh::add(), extendedEdgeMesh::allNearestFeatureEdges(), extendedEdgeMesh::allNearestFeaturePoints(), extendedEdgeMesh::edgeTree(), extendedEdgeMesh::edgeTreesByType(), extendedFeatureEdgeMesh::extendedFeatureEdgeMesh(), featureEdgeMesh::featureEdgeMesh(), searchableExtrudedCircle::findParametricNearest(), extendedEdgeMesh::flipNormals(), searchableExtrudedCircle::getNormal(), Foam::operator<<(), extendedEdgeMesh::pointTree(), STARCDedgeFormat::read(), refinementFeatures::regionEdgeTrees(), searchableExtrudedCircle::searchableExtrudedCircle(), OBJedgeFormat::write(), VTKedgeFormat::write(), edgeMeshFormat::write(), STARCDedgeFormat::write(), extendedEdgeMesh::writeObj(), edgeMesh::writeStats(), and extendedEdgeMesh::writeStats().
|
inline |
Return edges.
Definition at line 68 of file edgeMeshI.H.
Referenced by extendedEdgeMesh::add(), extendedEdgeMesh::allNearestFeatureEdges(), extendedEdgeMesh::edgeDirection(), extendedEdgeMesh::edgeTree(), extendedEdgeMesh::edgeTreesByType(), extendedFeatureEdgeMesh::extendedFeatureEdgeMesh(), featureEdgeMesh::featureEdgeMesh(), searchableExtrudedCircle::findParametricNearest(), extendedEdgeMesh::flipNormals(), searchableExtrudedCircle::getNormal(), extendedEdgeMesh::minDisconnectedDist(), Foam::operator<<(), refinementFeatures::regionEdgeTrees(), searchableExtrudedCircle::searchableExtrudedCircle(), OBJedgeFormat::write(), VTKedgeFormat::write(), edgeMeshFormat::write(), STARCDedgeFormat::write(), extendedEdgeMesh::writeObj(), edgeMesh::writeStats(), and extendedEdgeMesh::writeStats().
|
inline |
Return edges.
Definition at line 74 of file edgeMeshI.H.
Referenced by searchableExtrudedCircle::findParametricNearest(), edgeMesh::regions(), and extendedEdgeMesh::writeObj().
Foam::label regions | ( | labelList & | edgeRegion | ) | const |
Find connected regions. Set region number per edge.
Returns number of regions.
Definition at line 205 of file edgeMesh.C.
References List< T >::append(), Foam::e, forAll, edgeMesh::pointEdges(), List< T >::setSize(), List< T >::size(), and List< T >::transfer().
|
virtual |
Clear all storage.
Reimplemented in extendedEdgeMesh.
Definition at line 166 of file edgeMesh.C.
References List< T >::clear(), and edgeMesh::reset().
Referenced by extendedEdgeMesh::clear(), OBJedgeFormat::read(), and STARCDedgeFormat::read().
|
virtual |
Reset primitive data (points, edges)
Note, optimized to avoid overwriting data (with null)
Definition at line 175 of file edgeMesh.C.
References Foam::notNull(), and List< T >::transfer().
Referenced by extendedEdgeMesh::add(), edgeMesh::clear(), and extendedEdgeMesh::flipNormals().
|
virtual |
Scale points. A non-positive factor is ignored.
Definition at line 270 of file edgeMesh.C.
References edgeMesh::mergePoints().
|
virtual |
Merge common points (points within mergeDist). Return map from.
old to new points.
Definition at line 281 of file edgeMesh.C.
References Foam::e, forAll, forAllConstIter(), Foam::mergePoints(), List< T >::setSize(), List< T >::size(), List< T >::transfer(), and VectorSpace< Vector< scalar >, scalar, 3 >::zero.
Referenced by edgeMesh::scalePoints().
|
virtual |
Merge duplicate edges.
Definition at line 357 of file edgeMesh.C.
References Foam::e, Foam::endl(), forAll, forAllConstIter(), Foam::Info, List< T >::setSize(), and List< T >::size().
|
virtual |
Reimplemented in extendedEdgeMesh.
Definition at line 117 of file edgeMeshIO.C.
References edgeMesh::edges(), Foam::endl(), Foam::indent(), Foam::nl, edgeMesh::points(), and List< T >::size().
Referenced by extendedEdgeMesh::writeStats().
|
inlinevirtual |
Generic write routine. Chooses writer based on extension.
Reimplemented in STARCDedgeFormat, edgeMeshFormat, VTKedgeFormat, and OBJedgeFormat.
Definition at line 264 of file edgeMesh.H.
References edgeMesh::operator<<, edgeMesh::operator=(), edgeMesh::operator>>, and edgeMesh::write().
|
inline |
Definition at line 86 of file edgeMeshI.H.
Referenced by edgeMesh::write().
|
inline |
Definition at line 94 of file edgeMeshI.H.
Referenced by edgeMesh::write().
Referenced by edgeMesh::write().