SALOME - SMESH
SMESH_MeshVSLink.hxx
Go to the documentation of this file.
1 // SMESH SMESH_MeshVSLink : Connection of SMESH with MeshVS from OCC
2 //
3 // Copyright (C) 2003 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.
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 : SMESH_MeshVSLink.cxx
23 // Created : Mon Dec 1 09:00:00 2008
24 // Author : Sioutis Fotios
25 // Module : SMESH
26 
27 #ifndef _SMESH_MeshVSLink_HeaderFile
28 #define _SMESH_MeshVSLink_HeaderFile
29 
30 #ifndef _Standard_HeaderFile
31 #include <Standard.hxx>
32 #endif
33 #ifndef _Handle_SMESH_MeshVSLink_HeaderFile
35 #endif
36 #ifndef _TColStd_PackedMapOfInteger_HeaderFile
37 #include <TColStd_PackedMapOfInteger.hxx>
38 #endif
39 #ifndef _Handle_TColStd_HArray2OfInteger_HeaderFile
40 #include <Handle_TColStd_HArray2OfInteger.hxx>
41 #endif
42 #ifndef _Handle_TColStd_HArray2OfReal_HeaderFile
43 #include <Handle_TColStd_HArray2OfReal.hxx>
44 #endif
45 #ifndef _MeshVS_DataSource3D_HeaderFile
46 #include <MeshVS_DataSource3D.hxx>
47 #endif
48 #ifndef _Standard_Boolean_HeaderFile
49 #include <Standard_Boolean.hxx>
50 #endif
51 #ifndef _Standard_Integer_HeaderFile
52 #include <Standard_Integer.hxx>
53 #endif
54 #ifndef _MeshVS_EntityType_HeaderFile
55 #include <MeshVS_EntityType.hxx>
56 #endif
57 #ifndef _Standard_Address_HeaderFile
58 #include <Standard_Address.hxx>
59 #endif
60 #ifndef _Handle_TColStd_HArray1OfInteger_HeaderFile
61 #include <Handle_TColStd_HArray1OfInteger.hxx>
62 #endif
63 #ifndef _Standard_Real_HeaderFile
64 #include <Standard_Real.hxx>
65 #endif
66 #ifndef _SMESH_Mesh_HeaderFile
67 #include <SMESH_Mesh.hxx>
68 #endif
69 
71 
72  public:
73  // Methods PUBLIC
74  //
75 
77  Standard_EXPORT SMESH_MeshVSLink(const SMESH_Mesh *aMesh);
78 
79  //Not implemented yet
80  /*
81 
82  Standard_EXPORT Standard_Boolean GetNodeNormal(const Standard_Integer ranknode,const Standard_Integer ElementId,Standard_Real& nx,Standard_Real& ny,Standard_Real& nz) const;
83  Standard_EXPORT Standard_Boolean GetNormalsByElement(const Standard_Integer Id,const Standard_Boolean IsNodal,const Standard_Integer MaxNodes,Handle(TColStd_HArray1OfReal)& Normals) const;
84  Standard_EXPORT void GetAllGroups(TColStd_PackedMapOfInteger& Ids) const;
85  Standard_EXPORT Standard_Boolean GetGroup(const Standard_Integer Id,MeshVS_EntityType& Type,TColStd_PackedMapOfInteger& Ids) const;
86  Standard_EXPORT Standard_Address GetGroupAddr(const Standard_Integer ID) const;
87  Standard_EXPORT Standard_Boolean IsAdvancedSelectionEnabled() const;
88  Standard_EXPORT Bnd_Box GetBoundingBox() const;
89  Standard_EXPORT Standard_Boolean GetDetectedEntities(const Handle(MeshVS_Mesh)& Prs,const Standard_Real X,const Standard_Real Y,const Standard_Real aTol,Handle(TColStd_HPackedMapOfInteger)& Nodes,Handle(TColStd_HPackedMapOfInteger)& Elements) ;
90  Standard_EXPORT Standard_Boolean GetDetectedEntities(const Handle(MeshVS_Mesh)& Prs,const Standard_Real XMin,const Standard_Real YMin,const Standard_Real XMax,const Standard_Real YMax,const Standard_Real aTol,Handle(TColStd_HPackedMapOfInteger)& Nodes,Handle(TColStd_HPackedMapOfInteger)& Elements) ;
91  Standard_EXPORT Standard_Boolean GetDetectedEntities(const Handle(MeshVS_Mesh)& Prs,const TColgp_Array1OfPnt2d& Polyline,const Bnd_Box2d& aBox,const Standard_Real aTol,Handle(TColStd_HPackedMapOfInteger)& Nodes,Handle(TColStd_HPackedMapOfInteger)& Elements) ;
92  Standard_EXPORT Standard_Boolean GetDetectedEntities(const Handle(MeshVS_Mesh)& Prs,Handle(TColStd_HPackedMapOfInteger)& Nodes,Handle(TColStd_HPackedMapOfInteger)& Elements) ;
93  */
94 
99  Standard_EXPORT Standard_Boolean GetGeom(const Standard_Integer ID,const Standard_Boolean IsElement,TColStd_Array1OfReal& Coords,Standard_Integer& NbNodes,MeshVS_EntityType& Type) const;
100 
101  Standard_EXPORT Standard_Boolean Get3DGeom(const Standard_Integer ID,Standard_Integer& NbNodes,Handle(MeshVS_HArray1OfSequenceOfInteger)& Data) const;
102 
105  Standard_EXPORT Standard_Boolean GetGeomType(const Standard_Integer ID,const Standard_Boolean IsElement,MeshVS_EntityType& Type) const;
106 
108  Standard_EXPORT Standard_Address GetAddr(const Standard_Integer ID,const Standard_Boolean IsElement) const;
109 
111  Standard_EXPORT /*virtual*/ Standard_Boolean GetNodesByElement(const Standard_Integer ID,TColStd_Array1OfInteger& NodeIDs,Standard_Integer& NbNodes) const;
112 
114  Standard_EXPORT const TColStd_PackedMapOfInteger& GetAllNodes() const;
115 
117  Standard_EXPORT const TColStd_PackedMapOfInteger& GetAllElements() const;
118 
121  Standard_EXPORT Standard_Boolean GetNormal(const Standard_Integer Id,const Standard_Integer Max,Standard_Real& nx,Standard_Real& ny,Standard_Real& nz) const;
122 
124  Standard_EXPORT void GetAllGroups(TColStd_PackedMapOfInteger& Ids) const;
125 
126  // Type management
127  //
128  Standard_EXPORT const Handle(Standard_Type)& DynamicType() const;
129 
130  protected:
131  // Methods PROTECTED
132  //
133 
134  // Fields PROTECTED
135  //
136 
137  private:
138  // Methods PRIVATE
139  //
140 
141  // Fields PRIVATE
142  //
144  TColStd_PackedMapOfInteger myNodes;
145  TColStd_PackedMapOfInteger myElements;
146  TColStd_PackedMapOfInteger myGroups;
147 };
148 
149 // other Inline functions and methods (like "C++: function call" methods)
150 //
151 
152 #endif
T Max(const T &a, const T &b)
Definition: Rn.h:47