Version: 9.16.0
StdMeshers_Cartesian_VL.hxx
Go to the documentation of this file.
1// Copyright (C) 2007-2026 CEA, EDF, OPEN CASCADE
2//
3// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
4// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
5//
6// This library is free software; you can redistribute it and/or
7// modify it under the terms of the GNU Lesser General Public
8// License as published by the Free Software Foundation; either
9// version 2.1 of the License, or (at your option) any later version.
10//
11// This library is distributed in the hope that it will be useful,
12// but WITHOUT ANY WARRANTY; without even the implied warranty of
13// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14// Lesser General Public License for more details.
15//
16// You should have received a copy of the GNU Lesser General Public
17// License along with this library; if not, write to the Free Software
18// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
19//
20// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
21//
22// File : StdMeshers_Cartesian_VL.hxx
23// Created : Tue May 24 12:32:01 2022
24// Author : Edward AGAPOV (eap)
25
26#ifndef __StdMeshers_Cartesian_VL_HXX__
27#define __StdMeshers_Cartesian_VL_HXX__
28
29#include <BOPAlgo_Builder.hxx>
30#include <BRepOffset_MakeOffset.hxx>
31#include <BRepOffsetAPI_MakeOffset.hxx>
32
33#include <set>
34#include <map>
35#include <vector>
36
37class TopoDS_Face;
39class SMESH_Mesh;
40
42{
44 {
45 public:
46
47 ViscousBuilder( const StdMeshers_ViscousLayers* hypViscousLayers,
48 const SMESH_Mesh & theMesh,
49 const TopoDS_Shape & theShape);
51
52 TopoDS_Shape MakeOffsetShape(const TopoDS_Shape & theShape,
53 SMESH_Mesh & theMesh,
54 std::string & theError );
55
57
58 bool MakeViscousLayers( SMESH_Mesh & offsetMesh,
59 SMESH_Mesh & theMesh,
60 const TopoDS_Shape & theShape );
61
62 private:
63
64 TopoDS_Shape MakeOffsetSolid(const TopoDS_Shape & theShape,
65 SMESH_Mesh & theMesh,
66 std::string & theError );
67
68 bool CheckGeometryMaps( SMESH_Mesh & offsetMesh,
69 const TopoDS_Shape & theShape );
70
71 void getOffsetSubShape( const TopoDS_Shape& S, std::vector<TopoDS_Shape>& listOfShapes );
72
74 BRepOffset_MakeOffset _makeOffset;
75 std::vector<BRepOffset_MakeOffset*> _makeOffsetCollection; // collection to
76 BRepOffsetAPI_MakeOffset _makeFaceOffset; // to define shrink of planar faces. The face is shrink in all
77 BOPAlgo_Builder _solidCompound; // to glue solids with common faces after shrinking then with BRepOffset_MakeOffset
79 TopoDS_Shape _offsetShape;
80 std::set< int > _shapesWVL; // shapes with viscous layers
81 std::map< int, std::vector< int > > _edge2facesWOVL; // EDGE 2 FACEs w/o VL
82 };
83}
84
85#endif
Definition: SMESH_Mesh.hxx:80
Definition: StdMeshers_Cartesian_VL.hxx:44
SMESH_Mesh * MakeOffsetMesh()
Create a temporary mesh used to hold elements of the offset shape.
Definition: StdMeshers_Cartesian_VL.cxx:814
BRepOffsetAPI_MakeOffset _makeFaceOffset
Definition: StdMeshers_Cartesian_VL.hxx:76
std::set< int > _shapesWVL
Definition: StdMeshers_Cartesian_VL.hxx:80
BOPAlgo_Builder _solidCompound
Definition: StdMeshers_Cartesian_VL.hxx:77
TopoDS_Shape MakeOffsetSolid(const TopoDS_Shape &theShape, SMESH_Mesh &theMesh, std::string &theError)
Create an offset solid from a given one.
Definition: StdMeshers_Cartesian_VL.cxx:897
TopoDS_Shape MakeOffsetShape(const TopoDS_Shape &theShape, SMESH_Mesh &theMesh, std::string &theError)
Create an offset shape from a given one.
Definition: StdMeshers_Cartesian_VL.cxx:987
std::vector< BRepOffset_MakeOffset * > _makeOffsetCollection
Definition: StdMeshers_Cartesian_VL.hxx:75
~ViscousBuilder()
Destructor.
Definition: StdMeshers_Cartesian_VL.cxx:882
TopoDS_Shape _offsetShape
Definition: StdMeshers_Cartesian_VL.hxx:79
void getOffsetSubShape(const TopoDS_Shape &S, std::vector< TopoDS_Shape > &listOfShapes)
Return the list of sub-shape of the same type of the offset shape generated from a given initial sub-...
Definition: StdMeshers_Cartesian_VL.cxx:1032
ViscousBuilder(const StdMeshers_ViscousLayers *hypViscousLayers, const SMESH_Mesh &theMesh, const TopoDS_Shape &theShape)
Constructor.
Definition: StdMeshers_Cartesian_VL.cxx:825
BRepOffset_MakeOffset _makeOffset
Definition: StdMeshers_Cartesian_VL.hxx:74
SMESH_Mesh * _offsetMesh
Definition: StdMeshers_Cartesian_VL.hxx:78
const StdMeshers_ViscousLayers * _hyp
Definition: StdMeshers_Cartesian_VL.hxx:73
std::map< int, std::vector< int > > _edge2facesWOVL
Definition: StdMeshers_Cartesian_VL.hxx:81
bool CheckGeometryMaps(SMESH_Mesh &offsetMesh, const TopoDS_Shape &theShape)
Definition: StdMeshers_Cartesian_VL.cxx:1075
bool MakeViscousLayers(SMESH_Mesh &offsetMesh, SMESH_Mesh &theMesh, const TopoDS_Shape &theShape)
Create prismatic mesh between _offsetShape and theShape.
Definition: StdMeshers_Cartesian_VL.cxx:1113
Hypothesis defining parameters of viscous layers.
Definition: StdMeshers_ViscousLayers.hxx:41
Definition: StdMeshers_Cartesian_VL.hxx:42