ENH: support VTK output of point ids

- can be useful for diagnosing mesh internals and the locations of
  decomposed cells.
This commit is contained in:
Mark Olesen
2019-02-17 15:09:36 +01:00
committed by Andrew Heather
parent 9cb6338c58
commit fe445ac516
4 changed files with 103 additions and 0 deletions

View File

@ -313,7 +313,13 @@ Description
internalWriter->beginPointData
(
nVolFields + nDimFields + nPointFields
+ (withPointIds ? 1 : 0)
);
if (withPointIds)
{
internalWriter->writePointIDs();
}
}
forAll(patchWriters, writeri)

View File

@ -91,6 +91,9 @@ Usage
- \par -no-point-data
Suppress conversion of pointFields. No interpolated PointData.
- \par -with-point-ids
Additional pointID field for internal mesh
- \par -poly-decomp
Decompose polyhedral cells into tets/pyramids
@ -379,6 +382,12 @@ int main(int argc, char *argv[])
);
argList::addOptionCompat("no-point-data", {"noPointValues", 1806});
argList::addBoolOption
(
"with-point-ids",
"Additional pointID field for internal mesh"
);
argList::addBoolOption
(
"one-boundary", // allPatches
@ -495,6 +504,19 @@ int main(int argc, char *argv[])
<< nl;
}
const bool withPointIds = args.found("with-point-ids");
if (withPointIds)
{
Info<< "Write point ids requested";
if (noPointValues)
{
Info<< ", but ignored due to the '-no-point-data' option";
}
Info<< nl;
}
wordRes includePatches, excludePatches;
if (doBoundary)
{