63#ifndef Foam_debugSurfaceWriter_H
64#define Foam_debugSurfaceWriter_H
115 const word& fieldName,
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))
Generic templated field type that is much like a Foam::List except that it is expected to hold numeri...
A simple container for options an IOstream can normally have.
static bool parRun(const bool on) noexcept
Set as parallel run on/off.
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
A class for handling file names.
Abstract definition of a meshed surface defined by faces and points.
regIOobject is an abstract class derived from IOobject to handle automatic object registration with t...
surfaceWriter()
Default construct.
A surfaceWriter for special purpose debugging. Its definition and behaviour are subject to change at ...
virtual ~debugWriter()=default
Destructor.
debugWriter()
Default construct.
declareSurfaceWriterWriteMethod(symmTensor)
declareSurfaceWriterWriteMethod(sphericalTensor)
declareSurfaceWriterWriteMethod(tensor)
declareSurfaceWriterWriteMethod(label)
declareSurfaceWriterWriteMethod(scalar)
TypeNameNoDebug("debug")
Declare type-name, virtual type (without debug switch).
declareSurfaceWriterWriteMethod(vector)
virtual fileName write()
Write surface geometry to file.
A class for managing temporary objects.
A class for handling words, derived from Foam::string.
Namespace for surface writers.
List< face > faceList
List of faces.
vectorField pointField
pointField is a vectorField.
SphericalTensor< scalar > sphericalTensor
SphericalTensor of scalars, i.e. SphericalTensor<scalar>.
SymmTensor< scalar > symmTensor
SymmTensor of scalars, i.e. SymmTensor<scalar>.
#define declareSurfaceWriterWriteMethod(Type)
#define TypeNameNoDebug(TypeNameString)
Declare a ClassNameNoDebug() with extra virtual type info.