1 /*---------------------------------------------------------------------------*\
3 \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
5 \\ / A nd | Copyright (C) 2008-2011 OpenCFD Ltd.
7 -------------------------------------------------------------------------------
9 This file is part of OpenFOAM.
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.
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
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/>.
25 Foam::rawSurfaceWriter
28 A surfaceWriter for raw output.
33 \*---------------------------------------------------------------------------*/
35 #ifndef rawSurfaceWriter_H
36 #define rawSurfaceWriter_H
38 #include "surfaceWriter.H"
41 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
46 /*---------------------------------------------------------------------------*\
47 Class rawSurfaceWriter Declaration
48 \*---------------------------------------------------------------------------*/
50 class rawSurfaceWriter
54 // Private Member Functions
56 static inline void writeLocation
63 static inline void writeLocation
72 static void writeHeader
75 const word& fieldName,
80 static inline void writeData(Ostream&, const Type&);
83 //- Templated write operation
87 const fileName& outputDir,
88 const fileName& surfaceName,
89 const pointField& points,
90 const faceList& faces,
91 const word& fieldName,
92 const Field<Type>& values,
93 const bool isNodeValues,
100 //- Runtime type information
111 virtual ~rawSurfaceWriter();
116 //- Write single surface geometry to file.
119 const fileName& outputDir,
120 const fileName& surfaceName,
121 const pointField& points,
122 const faceList& faces,
123 const bool verbose = false
127 //- Write scalarField for a single surface to file.
128 // One value per face or vertex (isNodeValues = true)
131 const fileName& outputDir, // <case>/surface/TIME
132 const fileName& surfaceName, // name of surface
133 const pointField& points,
134 const faceList& faces,
135 const word& fieldName, // name of field
136 const Field<scalar>& values,
137 const bool isNodeValues,
138 const bool verbose = false
141 //- Write vectorField for a single surface to file.
142 // One value per face or vertex (isNodeValues = true)
145 const fileName& outputDir, // <case>/surface/TIME
146 const fileName& surfaceName, // name of surface
147 const pointField& points,
148 const faceList& faces,
149 const word& fieldName, // name of field
150 const Field<vector>& values,
151 const bool isNodeValues,
152 const bool verbose = false
155 //- Write sphericalTensorField for a single surface to file.
156 // One value per face or vertex (isNodeValues = true)
159 const fileName& outputDir, // <case>/surface/TIME
160 const fileName& surfaceName, // name of surface
161 const pointField& points,
162 const faceList& faces,
163 const word& fieldName, // name of field
164 const Field<sphericalTensor>& values,
165 const bool isNodeValues,
166 const bool verbose = false
169 //- Write symmTensorField for a single surface to file.
170 // One value per face or vertex (isNodeValues = true)
173 const fileName& outputDir, // <case>/surface/TIME
174 const fileName& surfaceName, // name of surface
175 const pointField& points,
176 const faceList& faces,
177 const word& fieldName, // name of field
178 const Field<symmTensor>& values,
179 const bool isNodeValues,
180 const bool verbose = false
183 //- Write tensorField for a single surface to file.
184 // One value per face or vertex (isNodeValues = true)
187 const fileName& outputDir, // <case>/surface/TIME
188 const fileName& surfaceName, // name of surface
189 const pointField& points,
190 const faceList& faces,
191 const word& fieldName, // name of field
192 const Field<tensor>& values,
193 const bool isNodeValues,
194 const bool verbose = false
200 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
202 } // End namespace Foam
204 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
208 // ************************************************************************* //