MCPcopy Create free account
hub / github.com/OpenFOAM/OpenFOAM-dev / writeHeader

Function writeHeader

src/surfMesh/surfaceFormats/vtk/VTKsurfaceFormatCore.C:31–52  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

29// * * * * * * * * * * * * Protected Member Functions * * * * * * * * * * * //
30
31void Foam::fileFormats::VTKsurfaceFormatCore::writeHeader
32(
33 Ostream& os,
34 const pointField& pointLst
35)
36{
37 // Write header
38 os << "# vtk DataFile Version 2.0" << nl
39 << "surface written " << clock::dateTime().c_str() << nl
40 << "ASCII" << nl
41 << nl
42 << "DATASET POLYDATA" << nl;
43
44 // Write vertex coords
45 os << "POINTS " << pointLst.size() << " float" << nl;
46 forAll(pointLst, ptI)
47 {
48 const point& pt = pointLst[ptI];
49
50 os << pt.x() << ' ' << pt.y() << ' ' << pt.z() << nl;
51 }
52}
53
54
55void Foam::fileFormats::VTKsurfaceFormatCore::writeTail

Callers 1

VTKsurfaceFormat.CFile · 0.70

Calls 5

forAllFunction · 0.50
sizeMethod · 0.45
xMethod · 0.45
yMethod · 0.45
zMethod · 0.45

Tested by

no test coverage detected