ENH: suppress cell/patch/proc ids for foamToVTK (#1230)

- reduces output size, consistent with vtkWrite function object

STYLE: mark some foamToVTK options as advanced (ie, visible with -help-full)
This commit is contained in:
Mark Olesen
2019-03-11 11:02:58 +01:00
committed by Andrew Heather
parent aafbca93b2
commit 5d445f4ed6
5 changed files with 55 additions and 17 deletions

View File

@ -121,14 +121,20 @@ Description
{
for (vtk::patchWriter& writer : patchWriters)
{
// Optionally with patchID, procID, neighID fields
// - use Pstream::parRun() not writer.parallel() !!
writer.beginCellData
(
1 + (Pstream::parRun() ? 2 : 0)
(withMeshIds ? 1 + (Pstream::parRun() ? 2 : 0) : 0)
+ nVolFields
);
writer.writePatchIDs();
writer.writeProcIDs();
writer.writeNeighIDs();
if (withMeshIds)
{
writer.writePatchIDs();
writer.writeProcIDs(); // parallel only
writer.writeNeighIDs(); // parallel only
}
}
writeAllVolFields