1 /*---------------------------------------------------------------------------*\
3 \\ / F ield | foam-extend: Open Source CFD
4 \\ / O peration | Version: 3.2
5 \\ / A nd | Web: http://www.foam-extend.org
6 \\/ M anipulation | For copyright notice see file Copyright
7 -------------------------------------------------------------------------------
9 This file is part of foam-extend.
11 foam-extend is free software: you can redistribute it and/or modify it
12 under the terms of the GNU General Public License as published by the
13 Free Software Foundation, either version 3 of the License, or (at your
14 option) any later version.
16 foam-extend is distributed in the hope that it will be useful, but
17 WITHOUT ANY WARRANTY; without even the implied warranty of
18 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
19 General Public License for more details.
21 You should have received a copy of the GNU General Public License
22 along with foam-extend. If not, see <http://www.gnu.org/licenses/>.
28 Write binary tecplot files using tecio.
32 tecplotWriterTemplates.C
34 \*---------------------------------------------------------------------------*/
36 #ifndef tecplotWriter_H
37 #define tecplotWriter_H
41 #include "indirectPrimitivePatch.H"
42 #include "volFields.H"
43 #include "surfaceFields.H"
47 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
54 /*---------------------------------------------------------------------------*\
55 Class tecplotWriter Declaration
56 \*---------------------------------------------------------------------------*/
66 //- Construct from components
67 tecplotWriter(const Time&);
75 const string& varNames,
77 INTEGER4 tecplotFileType
80 //- Write mesh as polyhedral zone
81 void writePolyhedralZone
84 const INTEGER4 strandID,
86 const List<INTEGER4>& varLocArray,
90 //- Write surface as polygonal zone
91 void writePolygonalZone
94 const INTEGER4 strandID,
95 const indirectPrimitivePatch& pp,
96 const List<INTEGER4>& varLocArray
99 //- Write unordered data (or rather 1D ordered)
100 void writeOrderedZone
102 const word& zoneName,
105 const List<INTEGER4>& varLocArray
109 void writeConnectivity(const fvMesh& mesh) const;
112 void writeConnectivity(const indirectPrimitivePatch& pp) const;
114 void writeEnd() const;
116 //- Write generic Field
118 void writeField(const Field<Type>& fld) const;
121 //- Get either fvPatchField or patchInternalField
123 tmp<Field<Type> > getPatchField
125 const bool nearCellValue,
126 const GeometricField<Type, fvPatchField, volMesh>& vfld,
130 //- Get mixed field: fvsPatchField for boundary faces and
131 // internalField for internal faces.
133 tmp<Field<Type> > getFaceField
135 const GeometricField<Type, fvsPatchField, surfaceMesh>&,
136 const labelList& faceLabels
139 template<class GeoField>
140 static wordList getNames(const PtrList<GeoField>&);
143 static void getTecplotNames
145 const wordList& names,
148 DynamicList<INTEGER4>& varLocation
151 template<class GeoField>
152 static void getTecplotNames
154 const PtrList<GeoField>& flds,
157 DynamicList<INTEGER4>& varLocation
163 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
165 } // End namespace Foam
167 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
170 # include "tecplotWriterTemplates.C"
174 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
178 // ************************************************************************* //