pathline.H
Go to the documentation of this file.
1 /*---------------------------------------------------------------------------*\
2  ========= |
3  \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4  \\ / O peration |
5  \\ / A nd | Copyright (C) 2015 OpenFOAM Foundation
6  \\/ M anipulation |
7 -------------------------------------------------------------------------------
8 License
9  This file is part of OpenFOAM.
10 
11  OpenFOAM is free software: you can redistribute it and/or modify it
12  under the terms of the GNU General Public License as published by
13  the Free Software Foundation, either version 3 of the License, or
14  (at your option) any later version.
15 
16  OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
17  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
18  FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
19  for more details.
20 
21  You should have received a copy of the GNU General Public License
22  along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
23 
24 Class
25  Foam::pathline
26 
27 Description
28 
29 SourceFiles
30  pathline.C
31 
32 \*---------------------------------------------------------------------------*/
33 
34 #ifndef pathline_H
35 #define pathline_H
36 
37 #include "geometryBase.H"
38 #include "NamedEnum.H"
39 #include "runTimeSelectionTables.H"
40 
41 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
42 
43 class vtkActor;
44 class vtkPolyData;
45 class vtkPolyDataMapper;
46 
47 namespace Foam
48 {
49 
50 /*---------------------------------------------------------------------------*\
51  Class pathline Declaration
52 \*---------------------------------------------------------------------------*/
53 
54 class pathline
55 :
56  public geometryBase
57 {
58 public:
59 
60  // Public enumerations
61 
63  {
67  rtVector
68  };
69 
71 
72 
73 private:
74 
75  // Private Member Functions
76 
77  //- Disallow default bitwise copy construct
78  pathline(const pathline&);
79 
80  //- Disallow default bitwise assignment
81  void operator=(const pathline&);
82 
83 
84 protected:
85 
86  // Protected data
87 
88  //- Representation type
90 
91  //- Radius for the tube filter
92  scalar tubeRadius_;
93 
94  //- Line colour
96 
97 
98  // Protected Member Functions
99 
100  //- Add the pathlines to the renderer
101  void addLines
102  (
103  const label frameI,
104  vtkActor* actor,
105  vtkPolyData* data
106  ) const;
107 
108 
109 public:
110 
111  //- Run-time type information
112  TypeName("pathline");
113 
114 
115  // Declare run-time constructor selection table
116 
118  (
119  autoPtr,
120  pathline,
121  dictionary,
122  (
124  const dictionary& dict,
126  ),
127  (parent, dict, colours)
128  );
129 
130 
131  // Constructors
132 
133  //- Construct from dictionary
134  pathline
135  (
137  const dictionary& dict,
139  );
140 
141 
142  // Selectors
143 
144  //- Return a reference to the selected RAS model
145  static autoPtr<pathline> New
146  (
148  const dictionary& dict,
150  const word& pathlineName
151  );
152 
153 
154  //- Destructor
155  virtual ~pathline();
156 };
157 
158 
159 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
160 
161 } // End namespace Foam
162 
163 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
164 
165 #endif
166 
167 // ************************************************************************* //
Foam::pathline::rtLine
@ rtLine
Definition: pathline.H:64
Foam::word
A class for handling words, derived from string.
Definition: word.H:59
NamedEnum.H
Foam::pathline::operator=
void operator=(const pathline &)
Disallow default bitwise assignment.
geometryBase.H
Foam::pathline::addLines
void addLines(const label frameI, vtkActor *actor, vtkPolyData *data) const
Add the pathlines to the renderer.
Definition: pathline.C:63
Foam::pathline::rtNone
@ rtNone
Definition: pathline.H:63
Foam::geometryBase
Definition: geometryBase.H:56
Foam::pathline::New
static autoPtr< pathline > New(const runTimePostProcessing &parent, const dictionary &dict, const HashPtrTable< DataEntry< vector >, word > &colours, const word &pathlineName)
Return a reference to the selected RAS model.
Definition: pathline.C:168
Foam::pathline::tubeRadius_
scalar tubeRadius_
Radius for the tube filter.
Definition: pathline.H:91
Foam::pathline::representationTypeNames
static const NamedEnum< representationType, 4 > representationTypeNames
Definition: pathline.H:69
Foam::pathline::pathline
pathline(const pathline &)
Disallow default bitwise copy construct.
Foam::runTimePostProcessing
Function object to generate images during run-time.
Definition: runTimePostProcessing.H:83
Foam::pathline
Definition: pathline.H:53
Foam::label
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
Definition: label.H:59
Foam::pathline::~pathline
virtual ~pathline()
Destructor.
Definition: pathline.C:199
Foam::geometryBase::colours
const HashPtrTable< DataEntry< vector >, word > & colours() const
Return reference to the colours.
Definition: geometryBase.C:143
Foam::pathline::rtTube
@ rtTube
Definition: pathline.H:65
dict
dictionary dict
Definition: searchingEngine.H:14
Foam::dictionary
A list of keyword definitions, which are a keyword followed by any number of values (e....
Definition: dictionary.H:137
Foam
Namespace for OpenFOAM.
Definition: combustionModel.C:30
Foam::geometryBase::parent
const runTimePostProcessing & parent() const
Return the reference to the parent function object.
Definition: geometryBase.C:118
Foam::autoPtr
An auto-pointer similar to the STL auto_ptr but with automatic casting to a reference to the type and...
Definition: PtrList.H:117
Foam::pathline::TypeName
TypeName("pathline")
Run-time type information.
Foam::HashPtrTable
A HashTable specialization for hashing pointers.
Definition: HashPtrTable.H:50
runTimeSelectionTables.H
Macros to ease declaration of run-time selection tables.
Foam::pathline::rtVector
@ rtVector
Definition: pathline.H:66
Foam::pathline::lineColour_
autoPtr< DataEntry< vector > > lineColour_
Line colour.
Definition: pathline.H:94
Foam::pathline::representation_
representationType representation_
Representation type.
Definition: pathline.H:88
Foam::pathline::representationType
representationType
Definition: pathline.H:61
Foam::DataEntry
Top level data entry class for use in dictionaries. Provides a mechanism to specify a variable as a c...
Definition: DataEntry.H:52
Foam::data
Database for solution data, solver performance and other reduced data.
Definition: data.H:52
Foam::pathline::declareRunTimeSelectionTable
declareRunTimeSelectionTable(autoPtr, pathline, dictionary,(const runTimePostProcessing &parent, const dictionary &dict, const HashPtrTable< DataEntry< vector >, word > &colours),(parent, dict, colours))
Foam::NamedEnum< representationType, 4 >