Go to the documentation of this file.
42 os <<
"# vtk DataFile Version 2.0" <<
nl
43 <<
"featureEdgeMesh written " << clock::dateTime().c_str() <<
nl
46 <<
"DATASET POLYDATA" <<
nl;
49 os <<
"POINTS " << pointLst.size() <<
" float" <<
nl;
52 const point& pt = pointLst[ptI];
54 os << pt.
x() <<
' ' << pt.
y() <<
' ' << pt.
z() <<
nl;
65 os <<
"LINES " << edgeLst.
size() <<
' ' << 3*edgeLst.
size() <<
nl;
69 const edge&
e = edgeLst[edgeI];
71 os <<
"2 " <<
e[0] <<
' ' <<
e[1] <<
nl;
98 <<
"Cannot read file " << filename
131 storedPoints().transfer(reader.
points());
136 nEdges += reader.
lines()[lineI].
size()-1;
138 storedEdges().setSize(nEdges);
146 storedEdges()[nEdges++] =
edge(verts[i-1], verts[i]);
164 <<
"Cannot open file for writing " << filename
168 writeHeader(os, eMesh.
points());
IOobject defines the attributes of an object for which implicit objectRegistry management is supporte...
Class to control time during OpenFOAM simulations that is also the top-level objectRegistry.
A class for handling file names.
#define forAll(list, i)
Loop across all elements in list.
bool read(const char *, int32_t &)
Reader for vtk unstructured_grid legacy files. Supports single CELLS, POINTS etc. entry only.
const pointField & points() const
Points.
An edge is a list of two point labels. The functionality it provides supports the discretisation on a...
Registry of regIOobjects.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
Pre-declare SubField and related Field type.
const pointField & points() const
Return points.
const edgeList & edges() const
Return edges.
errorManipArg< error, int > exit(error &err, const int errNo=1)
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
void writeEdges(const pointField &localPoints, const edgeList &edges, const label nInternalEdges)
A 1D array of objects of type <T>, where the size of the vector is known and used for subscript bound...
A 1D vector of objects of type <T>, where the size of the vector is known and can be used for subscri...
const dimensionedScalar e
Elementary charge.
void size(const label)
Override size to be inconsistent with allocated storage.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
bool good() const
Return true if next operation might succeed.
label size() const
Return the number of elements in the UList.
const labelListList & lines() const
1D cells (=open lines)
Points connected by edges.