Fixed URL for libccmio-2.6.1 (bug report #5 by Thomas Oliveira)
[foam-extend-3.2.git] / src / mesh / cfMesh / cartesianMesh / cartesianMeshExtractor / cartesianMeshExtractor.H
blobc5268ac908d66a7407592a3f0e4de18b1bdd8ca6
1 /*---------------------------------------------------------------------------*\
2   =========                 |
3   \\      /  F ield         | cfMesh: A library for mesh generation
4    \\    /   O peration     |
5     \\  /    A nd           | Author: Franjo Juretic (franjo.juretic@c-fields.com)
6      \\/     M anipulation  | Copyright (C) Creative Fields, Ltd.
7 -------------------------------------------------------------------------------
8 License
9     This file is part of cfMesh.
11     cfMesh 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     cfMesh 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.
21     You should have received a copy of the GNU General Public License
22     along with cfMesh.  If not, see <http://www.gnu.org/licenses/>.
24 Class
25     cartesianMeshExtractor
27 Description
28     Generates the cartesian mesh template from the octree
30 SourceFiles
31     cartesianMeshExtractor.C
33 \*---------------------------------------------------------------------------*/
35 #ifndef cartesianMeshExtractor_H
36 #define cartesianMeshExtractor_H
38 #include "polyMeshGenModifier.H"
39 #include "meshOctreeAddressing.H"
41 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
43 namespace Foam
46 class IOdictionary;
48 /*---------------------------------------------------------------------------*\
49                     Class cartesianMeshExtractor Declaration
50 \*---------------------------------------------------------------------------*/
52 class cartesianMeshExtractor
54     // Private data
55         //- reference to the octree addressing
56         meshOctreeAddressing octreeCheck_;
58         //- reference to the mesh
59         polyMeshGen& mesh_;
61         //- decompose split hex cells
62         bool decomposeSplitHexes_;
64         //- cell label for a given leaf
65         labelList* leafCellLabelPtr_;
67     // Private member functions
68         //- delete all freestore data
69         void clearOut();
71         //- create vertices and pointLeaves addressing
72         void createPointsAndAddressing();
74         //- create mesh data
75         void createPolyMesh();
77         //- decompose split hexes into pyramids and tets
78         void decomposeSplitHexesIntoTetsAndPyramids();
80     // Private copy constructor
81         //- Disallow default bitwise copy construct
82         cartesianMeshExtractor(const cartesianMeshExtractor&);
84         //- Disallow default bitwise assignment
85         void operator=(const cartesianMeshExtractor&);
87 public:
89     // Constructors
91         //- Construct from octree and mesh data
92         cartesianMeshExtractor
93         (
94             meshOctree& octree,
95             const IOdictionary& meshDict,
96             polyMeshGen& mesh
97         );
99     // Destructor
101         ~cartesianMeshExtractor();
104     // Member Functions
106         //- decompose split hexes into standard cells
107         void decomposeSplitHexes();
109         //- create the mesh with the above options
110         void createMesh();
114 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
116 } // End namespace Foam
118 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
120 #endif
122 // ************************************************************************* //