Forward compatibility: flex
[foam-extend-3.2.git] / src / mesh / cfMesh / utilities / triSurfaceTools / triSurfaceDetectFeatureEdges / triSurfaceDetectFeatureEdges.H
blobc55f5d6f8dc72cfaa566310a2d960adc02ad77a5
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     triSurfaceDetectFeatureEdges
27 Description
28     Divides the surface mesh into regions bounded by feature edges
30 SourceFiles
31     triSurfaceDetectFeatureEdges.C
32     triSurfaceDetectFeatureEdgesFunctions.C
34 \*---------------------------------------------------------------------------*/
36 #ifndef triSurfaceDetectFeatureEdges_H
37 #define triSurfaceDetectFeatureEdges_H
39 #include "triSurf.H"
40 #include "VRWGraph.H"
42 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
44 namespace Foam
47 /*---------------------------------------------------------------------------*\
48                 Class triSurfaceDetectFeatureEdges Declaration
49 \*---------------------------------------------------------------------------*/
51 class triSurfaceDetectFeatureEdges
53     // Private data
54         //- reference to triSurf
55         triSurf& surf_;
57         //- detected feature edges
58         List<direction> featureEdges_;
60         //- angle tolerance
61         scalar angleTolerance_;
63     // Private member functions
64         //- detect feature edges by check angle between the normals
65         //- of the two neighbouring facets
66         void detectFeatureEdgesAngleCriterion();
68         //- Disallow default bitwise copy construct
69         triSurfaceDetectFeatureEdges(const triSurfaceDetectFeatureEdges&);
71         //- Disallow default bitwise assignment
72         void operator=(const triSurfaceDetectFeatureEdges&);
74 public:
76     // Constructors
78         //- Construct from triSurface and tolerance
79         triSurfaceDetectFeatureEdges
80         (
81             triSurf& surface,
82             const scalar angleDeviation = 45.0
83         );
85     // Destructor
87         ~triSurfaceDetectFeatureEdges();
90     // Member Functions
92         //- store regions in a graph
93         void detectFeatureEdges();
96 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
98 } // End namespace Foam
100 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
102 #endif
104 // ************************************************************************* //