Encapsulation of volume meshes for writing in ensight format. It manages cellZones, facesZone, patches. More...
Classes | |
class | options |
Configuration options for the ensightMesh. More... | |
Public Member Functions | |
ensightMesh (const polyMesh &mesh) | |
Construct from mesh with all default options. More... | |
ensightMesh (const polyMesh &mesh, const options &opts) | |
Construct from components. More... | |
int | verbose () const noexcept |
Output verbosity level. More... | |
int | verbose (const int level) noexcept |
Change the output verbosity level. More... | |
const polyMesh & | mesh () const noexcept |
Reference to the underlying polyMesh. More... | |
const ensightMesh::options & | option () const |
Reference to the writer/mesh options. More... | |
const Map< ensightCells > & | cellZoneParts () const noexcept |
Face elements per selected patch, lookup by patch index. More... | |
const Map< ensightFaces > & | faceZoneParts () const noexcept |
Face elements per faceZone, lookup by zone index. More... | |
const Map< ensightFaces > & | boundaryParts () const noexcept |
Face elements per selected patch, lookup by patch index. More... | |
bool | empty () const noexcept |
Any parts? More... | |
label | size () const noexcept |
Number of parts. More... | |
bool | needsUpdate () const noexcept |
Does the content need an update? More... | |
bool | expire () |
Mark as needing an update. More... | |
void | correct () |
Update for new mesh. More... | |
void | write (ensightGeoFile &os, bool parallel=Pstream::parRun()) const |
Write geometry to file. Normally in parallel. More... | |
void | write (autoPtr< ensightGeoFile > &os, bool parallel=Pstream::parRun()) const |
Write geometry to file. Normally in parallel. More... | |
Static Public Attributes | |
static const label | internalZone = -1 |
The zone-id for internal mesh or unzoned cells. More... | |
Encapsulation of volume meshes for writing in ensight format. It manages cellZones, facesZone, patches.
When cellZones are present (and not disabled), the cells are grouped in parts according to the zone. Any remaining unzoned cells are placed into the "internalMesh" part, which is always part 0. If cellZones are missing or disabled, all cells are placed into the "internalMesh" part.
If one or more cellZones are explicitly requested, all other cells (including any unzoned cells) are ignored.
The converted patch faces are restricted by the volume mesh coverage. Except when the entire internal mesh has been explicitly suppressed.
Since the patches are subsetted by the internal mesh coverage, they are treated as indirect patches rather than regular poly patches.
Definition at line 82 of file ensightMesh.H.
|
explicit |
Construct from mesh with all default options.
Definition at line 96 of file ensightMesh.C.
ensightMesh | ( | const polyMesh & | mesh, |
const options & | opts | ||
) |
Construct from components.
Definition at line 105 of file ensightMesh.C.
References ensightMesh::correct(), and ensightMesh::option().
|
noexcept |
Output verbosity level.
Definition at line 125 of file ensightMesh.C.
|
noexcept |
|
inlinenoexcept |
Reference to the underlying polyMesh.
Definition at line 159 of file ensightMesh.H.
Referenced by Foam::writeDimFields(), Foam::ensightOutput::writePointField(), Foam::writePointFields(), and Foam::writeVolFields().
|
inline |
Reference to the writer/mesh options.
Definition at line 30 of file ensightMeshI.H.
Referenced by ensightMesh::ensightMesh().
|
inlinenoexcept |
Face elements per selected patch, lookup by patch index.
Process in sorted order. May require special treatment for zone -1 (internal).
Definition at line 170 of file ensightMesh.H.
Referenced by Foam::ensightOutput::writePointField(), and Foam::ensightOutput::writeVolField().
|
inlinenoexcept |
Face elements per faceZone, lookup by zone index.
Process in sorted order.
Definition at line 177 of file ensightMesh.H.
Referenced by Foam::ensightOutput::writePointField(), and Foam::ensightOutput::writeVolField().
|
inlinenoexcept |
Face elements per selected patch, lookup by patch index.
Process in sorted order.
Definition at line 184 of file ensightMesh.H.
Referenced by Foam::ensightOutput::writePointField(), and Foam::ensightOutput::writeVolField().
|
inlinenoexcept |
Any parts?
Definition at line 51 of file ensightMeshI.H.
|
inlinenoexcept |
Number of parts.
Definition at line 62 of file ensightMeshI.H.
|
inlinenoexcept |
Does the content need an update?
Definition at line 202 of file ensightMesh.H.
|
inline |
Mark as needing an update.
May also free up unneeded data. Return false if already marked as expired.
Definition at line 36 of file ensightMeshI.H.
References clear().
void correct | ( | ) |
Update for new mesh.
Definition at line 139 of file ensightMesh.C.
References bitSet::any(), ensightCells::classify(), ensightFaces::classify(), clear(), ensightCells::clear(), ensightFaces::clear(), PackedList< Width >::clearStorage(), PackedList< Width >::empty(), UList< T >::empty(), Foam::stringListOps::findMatching(), bitSet::flip(), faceZone::flipMap(), forAll, ensightPart::identifier(), Foam::identity(), ensightCells::info(), ensightFaces::info(), Foam::Info, wordRes::matching(), bitSet::none(), Foam::nonProcessorPatchNames(), p, patchId(), patchIds, patchNames(), ensightCells::reduce(), ensightFaces::reduce(), ensightPart::rename(), Foam::renumber(), PackedList< Width >::resize(), Foam::returnReduce(), bitSet::set(), UList< T >::size(), bitSet::test(), and ensightFaces::total().
Referenced by ensightMesh::ensightMesh().
void write | ( | ensightGeoFile & | os, |
bool | parallel = Pstream::parRun() |
||
) | const |
Write geometry to file. Normally in parallel.
Definition at line 428 of file ensightMesh.C.
References os().
|
inline |
Write geometry to file. Normally in parallel.
Definition at line 73 of file ensightMeshI.H.
|
static |
The zone-id for internal mesh or unzoned cells.
Definition at line 90 of file ensightMesh.H.