mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
BUG: foamToVTK patch/proc ids missing if there are no volume fields
This commit is contained in:
@ -264,7 +264,7 @@ Description
|
||||
// Begin CellData
|
||||
if (internalWriter)
|
||||
{
|
||||
// Optionally with cellID and procID fields
|
||||
// Optionally with (cellID, procID) fields
|
||||
internalWriter->beginCellData
|
||||
(
|
||||
(withMeshIds ? 1 + (internalWriter->parallel() ? 1 : 0) : 0)
|
||||
@ -278,20 +278,21 @@ Description
|
||||
}
|
||||
}
|
||||
|
||||
if (nVolFields)
|
||||
if (nVolFields || withMeshIds)
|
||||
{
|
||||
for (vtk::patchWriter& writer : patchWriters)
|
||||
{
|
||||
// Optionally with patchID field
|
||||
// Optionally with (patchID, procID) fields
|
||||
writer.beginCellData
|
||||
(
|
||||
(withMeshIds ? 1 : 0)
|
||||
(withMeshIds ? 2 : 0)
|
||||
+ nVolFields
|
||||
);
|
||||
|
||||
if (withMeshIds)
|
||||
{
|
||||
writer.writePatchIDs();
|
||||
writer.writeProcIDs();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user