STYLE: adjust feedback comments in foamToVTK
This commit is contained in:
parent
cde12ad9e5
commit
7ee1dba43a
@ -122,10 +122,7 @@ Note
|
|||||||
|
|
||||||
\verbatim
|
\verbatim
|
||||||
<?xml version="1.0"?>
|
<?xml version="1.0"?>
|
||||||
<VTKFile type="Collection"
|
<VTKFile type="Collection" version="0.1" byte_order="LittleEndian">
|
||||||
version="0.1"
|
|
||||||
byte_order="LittleEndian"
|
|
||||||
compressor="vtkZLibDataCompressor">
|
|
||||||
<Collection>
|
<Collection>
|
||||||
<DataSet timestep="50" file="pitzDaily_2.vtu"/>
|
<DataSet timestep="50" file="pitzDaily_2.vtu"/>
|
||||||
<DataSet timestep="100" file="pitzDaily_3.vtu"/>
|
<DataSet timestep="100" file="pitzDaily_3.vtu"/>
|
||||||
@ -261,7 +258,7 @@ vtk::outputOptions getOutputOptions(const argList& args)
|
|||||||
opts.ascii(true);
|
opts.ascii(true);
|
||||||
|
|
||||||
WarningInFunction
|
WarningInFunction
|
||||||
<< "Using ASCII rather than binary VTK format since "
|
<< "Using ASCII rather than legacy binary VTK format since "
|
||||||
<< "floatScalar and/or label are not 4 bytes in size."
|
<< "floatScalar and/or label are not 4 bytes in size."
|
||||||
<< nl << endl;
|
<< nl << endl;
|
||||||
}
|
}
|
||||||
@ -434,8 +431,9 @@ int main(int argc, char *argv[])
|
|||||||
|
|
||||||
if (noPointValues)
|
if (noPointValues)
|
||||||
{
|
{
|
||||||
WarningInFunction
|
Info<< "Outputting cell values only."
|
||||||
<< "Outputting cell values only" << nl << endl;
|
<< " Point fields disabled by '-noPointValues' option"
|
||||||
|
<< nl;
|
||||||
}
|
}
|
||||||
|
|
||||||
const bool allPatches = args.optionFound("allPatches");
|
const bool allPatches = args.optionFound("allPatches");
|
||||||
@ -676,11 +674,13 @@ int main(int argc, char *argv[])
|
|||||||
}
|
}
|
||||||
|
|
||||||
const label nVolFields =
|
const label nVolFields =
|
||||||
vScalarFld.size()
|
(
|
||||||
+ vVectorFld.size()
|
vScalarFld.size()
|
||||||
+ vSphTensorf.size()
|
+ vVectorFld.size()
|
||||||
+ vSymTensorFld.size()
|
+ vSphTensorf.size()
|
||||||
+ vTensorFld.size();
|
+ vSymTensorFld.size()
|
||||||
|
+ vTensorFld.size()
|
||||||
|
);
|
||||||
|
|
||||||
|
|
||||||
// Construct dimensioned fields
|
// Construct dimensioned fields
|
||||||
@ -744,29 +744,23 @@ int main(int argc, char *argv[])
|
|||||||
}
|
}
|
||||||
|
|
||||||
const label nDimFields =
|
const label nDimFields =
|
||||||
dScalarFld.size()
|
(
|
||||||
+ dVectorFld.size()
|
dScalarFld.size()
|
||||||
+ dSphTensorFld.size()
|
+ dVectorFld.size()
|
||||||
+ dSymTensorFld.size()
|
+ dSphTensorFld.size()
|
||||||
+ dTensorFld.size();
|
+ dSymTensorFld.size()
|
||||||
|
+ dTensorFld.size()
|
||||||
|
);
|
||||||
|
|
||||||
|
|
||||||
// Construct pointMesh only if necessary since constructs edge
|
|
||||||
// addressing (expensive on polyhedral meshes)
|
|
||||||
if (noPointValues)
|
|
||||||
{
|
|
||||||
Info<< " pointScalarFields : switched off"
|
|
||||||
<< " (\"-noPointValues\" (at your option)\n";
|
|
||||||
Info<< " pointVectorFields : switched off"
|
|
||||||
<< " (\"-noPointValues\" (at your option)\n";
|
|
||||||
}
|
|
||||||
|
|
||||||
PtrList<const pointScalarField> pScalarFld;
|
PtrList<const pointScalarField> pScalarFld;
|
||||||
PtrList<const pointVectorField> pVectorFld;
|
PtrList<const pointVectorField> pVectorFld;
|
||||||
PtrList<const pointSphericalTensorField> pSphTensorFld;
|
PtrList<const pointSphericalTensorField> pSphTensorFld;
|
||||||
PtrList<const pointSymmTensorField> pSymTensorFld;
|
PtrList<const pointSymmTensorField> pSymTensorFld;
|
||||||
PtrList<const pointTensorField> pTensorFld;
|
PtrList<const pointTensorField> pTensorFld;
|
||||||
|
|
||||||
|
// Construct pointMesh only if necessary since it constructs edge
|
||||||
|
// addressing (expensive on polyhedral meshes)
|
||||||
if (!noPointValues && !(specifiedFields && selectedFields.empty()))
|
if (!noPointValues && !(specifiedFields && selectedFields.empty()))
|
||||||
{
|
{
|
||||||
readFields
|
readFields
|
||||||
@ -797,7 +791,7 @@ int main(int argc, char *argv[])
|
|||||||
selectedFields,
|
selectedFields,
|
||||||
pSphTensorFld
|
pSphTensorFld
|
||||||
);
|
);
|
||||||
print(" pointSphericalTensor :", Info, pSphTensorFld);
|
print(" pointSphTensor : ", Info, pSphTensorFld);
|
||||||
|
|
||||||
readFields
|
readFields
|
||||||
(
|
(
|
||||||
@ -819,7 +813,6 @@ int main(int argc, char *argv[])
|
|||||||
);
|
);
|
||||||
print(" pointTensor :", Info, pTensorFld);
|
print(" pointTensor :", Info, pTensorFld);
|
||||||
}
|
}
|
||||||
Info<< endl;
|
|
||||||
|
|
||||||
const label nPointFields =
|
const label nPointFields =
|
||||||
pScalarFld.size()
|
pScalarFld.size()
|
||||||
@ -901,6 +894,7 @@ int main(int argc, char *argv[])
|
|||||||
|
|
||||||
// Interpolated volFields
|
// Interpolated volFields
|
||||||
volPointInterpolation pInterp(mesh);
|
volPointInterpolation pInterp(mesh);
|
||||||
|
|
||||||
writer.write(pInterp, vScalarFld);
|
writer.write(pInterp, vScalarFld);
|
||||||
writer.write(pInterp, vVectorFld);
|
writer.write(pInterp, vVectorFld);
|
||||||
writer.write(pInterp, vSphTensorf);
|
writer.write(pInterp, vSphTensorf);
|
||||||
@ -1051,8 +1045,8 @@ int main(int argc, char *argv[])
|
|||||||
writer.write(pSymTensorFld);
|
writer.write(pSymTensorFld);
|
||||||
writer.write(pTensorFld);
|
writer.write(pTensorFld);
|
||||||
|
|
||||||
// no interpolated volFields since I cannot be bothered to
|
// no interpolated volFields to avoid creating
|
||||||
// create the patchInterpolation for all subpatches.
|
// patchInterpolation for all subpatches.
|
||||||
|
|
||||||
writer.endPointData();
|
writer.endPointData();
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user