The visualization module is a collection of visualization interfaces for OpenFOAM, primarily VTK/ParaView based. It is provided as a module to isolate library dependencies and support multi-build paradigms (eg, different VTK or ParaView versions, different rendering types etc).
Incorporating visualization increases the complexity (potential difficulty and issues) of the software build. It is considered an intermediate to advanced topic and should be avoided by first-time OpenFOAM users.
Things to consider:
- hardware vs. software rendering
- llvm pipelines
- mpi flavours
- what do I really need?
Building VTK libraries for use with OpenFOAM is relative straightforward, as is using pre-compiled VTK libraries.
Building ParaView becomes more complex, since it involves many more software components (the QT dependencies are often the ones that cause the most difficulty). Even using a pre-compiled set of ParaView binaries may prove difficult, since they often lack the necessary development headers for creating additional plugins.
In light of these potential difficulties, it is worthwhile carefully examining the following section.
Do I really need the ParaView plugins?
Before blindly launching into compiling ParaView with the idea that this is simply necessary for a complete software stack, you should examine your actual requirements. Note that the term paraFoam is often used loosely to mean the reader plugins, but it is merely a small wrapper script.
|Native reader||OpenFOAM Plugin||Functionality|
|[+]||[-]||Does not require OpenFOAM installation|
|[+]||[-]||No duplicate of the OpenFOAM mesh in memory|
|[+]||[-]||Supports decomposed cases (without reconstructPar)|
|[+]||[-]||Supports parallel rendering|
|[-]||[+]||Handles collated file formats|
|[-]||[+]||Selection of faceSet, faceZones, etc.|
|[-]||[+]||Support finiteArea mesh and results|
|[paraview-5.10]||[+]||Patch group selection - merged|
|[paraview-5.10]||[+]||Dimensioned (Internal) fields - merged|
|[-]||[+]||Additional patch names (low priority)|
foamToVTKfor faceSets, faceZones as required and load the generated VTK files in ParaView as usual.
|Native reader||blockMeshDict Plugin||Functionality|
|n/a||[+]||Explore block structures|
blockMesh -write-vtkto generate the block topology as a VTK file that can be explored in ParaView as required.
Which plugins are loaded?
From the paraview menu: Tools / Manage Plugins...
Recommend using the native (builtin) ParaView/VTK reader for most normal cases. For example,
If you do this frequently enough, the following alias can be quite convenient:
alias parafoam='touch log.foam; paraview log.foam'
Copyright (C) 2020-2021 OpenCFD Ltd.