39 const fileName& fileName,
40 const UPtrList<const surfaceVectorField>& surfVectorFields
43 const fvMesh& mesh = vMesh.mesh();
45 std::ofstream str(fileName.c_str());
58 str <<
"POINTS " << mesh.nFaces() <<
" float" <<
std::endl;
60 DynamicList<floatScalar> pField(3*mesh.nFaces());
62 for (
label facei = 0; facei < mesh.nFaces(); facei++)
69 str <<
"POINT_DATA " << mesh.nFaces() <<
std::endl
70 <<
"FIELD attributes " << surfVectorFields.size() <<
std::endl;
73 forAll(surfVectorFields, fieldi)
77 str << svf.name() <<
" 3 "
78 << mesh.nFaces() <<
" float" <<
std::endl;
80 DynamicList<floatScalar> fField(3*mesh.nFaces());
82 for (
label facei = 0; facei < mesh.nInternalFaces(); facei++)
91 const fvPatch& pp = mesh.boundary()[
patchi];
93 if (isA<emptyFvsPatchVectorField>(pf))
#define forAll(list, i)
Loop across all elements in list.
void insert(const scalar, DynamicList< floatScalar > &)
Append scalar to given DynamicList.
void write(std::ostream &os, const bool binary, List< floatScalar > &fField)
Write floats ascii or binary.
void writeHeader(std::ostream &, const bool isBinary, const std::string &title)
Write header.
void writeSurfFields(const bool binary, const vtkMesh &vMesh, const fileName &fileName, const UPtrList< const surfaceVectorField > &surfVectorFields)
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
Ostream & endl(Ostream &os)
Add newline and flush stream.
vectorField pointField
pointField is a vectorField.
SurfaceField< vector > surfaceVectorField
fvsPatchField< vector > fvsPatchVectorField
Write a patch with its data.