Commit fe7832cf authored by Mark Olesen's avatar Mark Olesen

STYLE: cleanup headers

parent b8796587
......@@ -3,12 +3,22 @@ cd ${0%/*} || exit 1 # Run from this directory
targetType=libso
. $WM_PROJECT_DIR/wmake/scripts/AllwmakeParseArguments
[ -n "$FOAM_USER_LIBBIN" ] || {
echo "Error: FOAM_USER_LIBBIN not set"
echo " Check the OpenFOAM entries in your dot-files and source them."
exit 1
}
#------------------------------------------------------------------------------
echo "========================================"
date "+%Y-%m-%d %H:%M:%S %z" 2>/dev/null || echo "date is unknown"
echo "Starting compile of catalyst with ${WM_PROJECT_DIR##*/} ${0##*}"
echo " $WM_COMPILER $WM_COMPILER_TYPE compiler"
echo " ${WM_OPTIONS}, with ${WM_MPLIB} ${FOAM_MPI}"
echo
src/Allwmake $targetType $*
src/Allwmake
# Some summary information
echo
date "+%Y-%m-%d %H:%M:%S %z" 2>/dev/null || echo "date is unknown"
echo "========================================"
echo " Finished compile of catalyst with ${WM_PROJECT_DIR##*/}"
echo " $WM_COMPILER $WM_COMPILER_TYPE compiler"
echo " ${WM_OPTIONS}, with ${WM_MPLIB} ${FOAM_MPI}"
echo
#------------------------------------------------------------------------------
......@@ -30,25 +30,33 @@ Group
Description
A Paraview Catalyst adaptor for a single OpenFOAM cloud (lagrangian).
The output comprises a single "cloud" channel, which is a multi-block
dataset (one block per cloud).
Example of function object specification:
\verbatim
catalystCloud1
{
type catalyst::cloud;
libs ("libcatalystFoam.so");
executeControl timeStep;
executeInterval 101;
cloud NAME;
fields (U T rho);
scripts ( ... );
executeControl timeStep;
executeInterval 1;
}
\endverbatim
Usage
\table
Property | Description | Required | Default value
cloud | | no | defaultCloud
clouds | List of wordRe | no |
Property | Description | Required | Default value
type | catalyst::cloud | yes |
cloud | | no | defaultCloud
clouds | wordRe list of clouds | no |
region | | no | region0
regions | wordRe list of regions | no |
fields | wordRe list of fields | yes |
scripts | Python pipeline scripts | yes |
\endtable
See also
......
......@@ -27,6 +27,7 @@ License
#include "catalystCoprocess.H"
#include "addToRunTimeSelectionTable.H"
#include "faMesh.H"
#include "fvMesh.H"
#include <vtkNew.h>
#include <vtkCPDataDescription.h>
......
......@@ -30,29 +30,34 @@ Group
Description
A Paraview Catalyst adaptor for OpenFOAM faMesh regions.
The output comprises a single "input" channel, which is a multi-block
dataset (one block per area mesh).
Example of function object specification:
\verbatim
catalyst
{
type catalyst;
type catalyst::area;
libs ("libcatalystFoam.so");
writeControl writeTime;
writeInterval 1;
regions ( ".*Solid" )
fields (U p);
scripts ( ... );
executeControl timeStep;
executeInterval 1;
}
\endverbatim
Usage
\table
Property | Description | Required | Default value
region | | no | region0
regions | List of wordRe | no |
Property | Description | Required | Default
type | catalyst::area | yes |
region | | no | region0
regions | wordRe list of regions | no |
fields | wordRe list of fields | yes |
scripts | Python pipeline scripts | yes |
\endtable
See also
Foam::functionObjects::functionObject
Foam::functionObjects::fvMeshFunctionObject
Foam::functionObjects::timeControl
SourceFiles
......
......@@ -30,25 +30,31 @@ Group
Description
A Paraview Catalyst adaptor for OpenFOAM fvMesh regions.
The output comprises up to three channels ("input", "mesh", "patches"),
each of which is a multi-block dataset.
Example of function object specification:
\verbatim
catalyst
{
type catalyst;
libs ("libcatalystFoam.so");
writeControl writeTime;
writeInterval 1;
regions ( ".*Solid" )
fields (U p);
scripts ( ... );
executeControl timeStep;
executeInterval 1;
}
\endverbatim
Usage
\table
Property | Description | Required | Default value
region | | no | region0
regions | List of wordRe | no |
Property | Description | Required | Default
type | catalyst | yes |
region | | no | region0
regions | wordRe list of regions | no |
fields | wordRe list of fields | yes |
scripts | Python pipeline scripts | yes |
\endtable
See also
......
......@@ -167,15 +167,15 @@ vtkSmartPointer<vtkMultiPieceDataSet>
Foam::vtk::cloudAdaptor::getCloud
(
const word& cloudName,
const wordRes& matcher
const wordRes& selectFields
) const
{
if (matcher.empty())
if (selectFields.empty())
{
return getCloud(cloudName);
}
return getCloudImpl(mesh_, cloudName, matcher);
return getCloudImpl(mesh_, cloudName, selectFields);
}
......
......@@ -27,6 +27,10 @@ Class
Description
A simple backend for converting an OpenFOAM cloud to vtkPolyData.
The output is a multi-piece PolyData dataset corresponding to the
cloud. Each piece corresponds to its MPI rank.
Note
No caching of converted data since clouds are not stationary.
SourceFiles
......@@ -42,10 +46,8 @@ SourceFiles
#include "Enum.H"
#include "foamVtkTools.H"
#include <vtkPoints.h>
#include <vtkPolyData.h>
#include <vtkSmartPointer.h>
#include <vtkMultiBlockDataSet.h>
#include <vtkMultiPieceDataSet.h>
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
......@@ -140,7 +142,7 @@ public:
vtkSmartPointer<vtkMultiPieceDataSet> getCloud
(
const word& cloudName,
const wordRes& fieldsSubset
const wordRes& selectFields
) const;
};
......
......@@ -27,6 +27,9 @@ Class
Description
The backend for the catalystFaMesh function object.
The output is a multi-piece PolyData dataset corresponding to the
finite area mesh. Each piece corresponds to its MPI rank.
SourceFiles
foamVtkFaMeshAdaptor.C
foamVtkFaMeshAdaptorGeom.C
......@@ -43,10 +46,8 @@ SourceFiles
#include "stringList.H"
#include "wordList.H"
#include "Enum.H"
#include "polyMesh.H"
#include "areaFieldsFwd.H"
#include "primitivePatch.H"
#include "PrimitivePatchInterpolation.H"
#include "volPointInterpolation.H"
#include "foamVtkTools.H"
#include "foamVtkMeshMaps.H"
......@@ -68,10 +69,9 @@ class vtkIndent;
namespace Foam
{
// OpenFOAM class forward declarations
// Forward declarations
class Time;
class faMesh;
template<class Type> class Field;
namespace vtk
......@@ -103,9 +103,6 @@ public:
private:
// Convenience typedefs
typedef PrimitivePatchInterpolation<primitivePatch> patchInterpolator;
//- Bookkeeping for vtkPolyData
struct foamVtpData
:
......@@ -126,13 +123,16 @@ private:
HashTable<foamVtpData, string> cachedVtp_;
// Mesh Conversion Functions
// Mesh Conversion
//- Convert internal
void convertGeometryInternal();
// Field conversion functions
// Field Conversion
//- Convert specified area fields
void convertAreaFields(const wordRes& selectFields);
//- Area field
template<class Type>
......@@ -143,22 +143,20 @@ private:
) const;
//- Convert specified area fields
void convertAreaFields(const wordRes& selectFields);
//- Update geometry and fields
void updateContent(const wordRes& selectFields);
// Convert OpenFOAM fields
//- Volume field - all types
//- Area field - all types
template<class Type>
void convertAreaField
(
const GeometricField<Type, faPatchField, areaMesh>& fld
);
//- Volume fields - all types
//- Area fields - all types
template<class Type>
void convertAreaFields(const wordRes& selectFields);
......@@ -191,22 +189,16 @@ public:
// Member Functions
//- Return the names of known (supported fields)
//- Return the names of known (supported) fields
wordHashSet knownFields(const wordRes& selectFields) const;
void updateState(polyMesh::readUpdateState state);
//- The output with point/cell data.
vtkSmartPointer<vtkMultiPieceDataSet>
output(const wordRes& selectFields);
// Access
//- Debug information
void PrintSelf(ostream&, vtkIndent) const;
void printInfo() const;
//- The output with cell data.
vtkSmartPointer<vtkMultiPieceDataSet> output
(
const wordRes& selectFields
);
};
......
......@@ -2,8 +2,8 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation
\\/ M anipulation | Copyright (C) 2017 OpenCFD Ltd.
\\ / A nd | Copyright (C) 2017-2018 OpenCFD Ltd.
\\/ M anipulation |
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
......@@ -28,7 +28,6 @@ License
// OpenFOAM includes
#include "fvMesh.H"
#include "Time.H"
// VTK includes
#include <vtkMultiBlockDataSet.h>
......
......@@ -27,6 +27,14 @@ Class
Description
The backend for the catalystFvMesh function object.
The output is a multi-block dataset with two blocks corresponding
to the internal (volume) mesh (block 0) and the patches as (block 1).
These two blocks correspond simultaneously to the catalyst channels
"mesh" and "patches", respectively.
The patches are further divided into sub-blocks. The lowest data blocks
are multi-piece datasets (UnstructuredGrid and PolyData for internal mesh
and patches, respectively) with each piece corresponding to its MPI rank.
SourceFiles
foamVtkFvMeshAdaptor.C
foamVtkFvMeshAdaptorGeom.C
......@@ -68,10 +76,8 @@ class vtkIndent;
namespace Foam
{
// OpenFOAM class forward declarations
class Time;
// Forward declarations
class fvMesh;
template<class Type> class Field;
namespace vtk
......@@ -166,7 +172,7 @@ private:
HashTable<foamVtuData, string> cachedVtu_;
// Mesh Conversion Functions
// Mesh Conversion
//- Convert internal
void convertGeometryInternal();
......@@ -177,7 +183,10 @@ private:
void convertGeometryPatches();
// Field conversion functions
// Field Conversion
//- Convert specified volume fields
void convertVolFields(const wordRes& selectFields);
//- Volume field
template<class Type>
......@@ -188,14 +197,6 @@ private:
) const;
//- Convert specified volume fields
void convertVolFields(const wordRes& selectFields);
void updateContent(const wordRes& selectFields);
// Convert OpenFOAM fields
//- Volume field - all types
template<class Type>
void convertVolField
......@@ -238,6 +239,10 @@ private:
);
//- Update geometry and fields
void updateContent(const wordRes& selectFields);
// Constructors
//- No copy construct
......@@ -282,23 +287,17 @@ public:
//- used - otherwise 0.
label nPatches() const;
//- Return the names of known (supported fields)
//- Return the names of known (supported) fields
wordHashSet knownFields(const wordRes& selectFields) const;
void updateState(polyMesh::readUpdateState state);
//- The output is a pair (MESH/PATCHES channels) of vtk meshes with
//- point/cell data.
vtkSmartPointer<vtkMultiBlockDataSet>
output(const wordRes& selectFields);
// Access
//- Debug information
void PrintSelf(ostream&, vtkIndent) const;
void printInfo() const;
vtkSmartPointer<vtkMultiBlockDataSet> output
(
const wordRes& selectFields
);
};
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment