38#ifndef Foam_ensightOutputCloud_H
39#define Foam_ensightOutputCloud_H
184 #include "ensightOutputCloud.txx"
const word cloudName(propsDict.get< word >("cloud"))
Info<< nl;Info<< "Write faMesh in vtk format:"<< nl;{ vtk::uindirectPatchWriter writer(aMesh.patch(), fileName(aMesh.time().globalPath()/vtkBaseFileName));writer.writeGeometry();globalIndex procAddr(aMesh.nFaces());labelList cellIDs;if(UPstream::master()) { cellIDs.resize(procAddr.totalSize());for(const labelRange &range :procAddr.ranges()) { auto slice=cellIDs.slice(range);slice=identity(range);} } writer.beginCellData(4);writer.writeProcIDs();writer.write("cellID", cellIDs);writer.write("area", aMesh.S().field());writer.write("normal", aMesh.faceAreaNormals());writer.beginPointData(1);writer.write("normal", aMesh.pointAreaNormals());Info<< " "<< writer.output().name()<< nl;}{ vtk::lineWriter writer(aMesh.points(), aMesh.edges(), fileName(aMesh.time().globalPath()/(vtkBaseFileName+"-edges")));writer.writeGeometry();writer.beginCellData(4);writer.writeProcIDs();{ Field< scalar > fld(faMeshTools::flattenEdgeField(aMesh.magLe(), true))
A 1D vector of objects of type <T> that resizes itself as necessary to accept the new objects.
Defines the attributes of an object for which implicit objectRegistry management is supported,...
A 1D vector of objects of type <T>, where the size of the vector is known and can be used for subscri...
A variant of OFstream with specialised handling for Ensight writing of strings, integers and floats (...
Mesh data needed to do the Finite Volume discretisation.
Calculates a non-overlapping list of offsets based on an input size (eg, number of cells) from differ...
A class for handling words, derived from Foam::string.
OBJstream os(runTime.globalPath()/outputName)
Implementation details and output backends that would not normally be called directly by a user.
label writeCloudFieldContent(ensightFile &os, const UList< Type > &fld, label count=0)
Write cloud field data (serial) with rounding and newlines.
A collection of functions for writing ensight file content.
bool writeCloudField(ensightFile &os, const UList< Type > &field, const globalIndex &procAddr)
Write cloud field, returning true if the field is non-empty.
bool writeCloudPositions(ensightFile &os, DynamicList< floatVector > &positions, const globalIndex &procAddr)
Write cloud positions.
bool readWriteCloudField(ensightFile &os, const IOobject &fieldObject, bool existsAny)
Read cloud field from IOobject (if exists == true) and write, always returning true.
bool exists(const fileName &name, const bool checkGzip=true, const bool followLink=true)
Does the name exist (as DIRECTORY or FILE) in the file system?