1 // Copyright (C) 2017-2024 CEA, EDF
3 // This library is free software; you can redistribute it and/or
4 // modify it under the terms of the GNU Lesser General Public
5 // License as published by the Free Software Foundation; either
6 // version 2.1 of the License, or (at your option) any later version.
8 // This library is distributed in the hope that it will be useful,
9 // but WITHOUT ANY WARRANTY; without even the implied warranty of
10 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 // Lesser General Public License for more details.
13 // You should have received a copy of the GNU Lesser General Public
14 // License along with this library; if not, write to the Free Software
15 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
19 // File : FrontTrack_NodeGroups.hxx
20 // Created : Tue Apr 25 19:02:49 2017
21 // Author : Edward AGAPOV (eap)
23 #ifndef __FrontTrack_NodeGroups_HXX__
24 #define __FrontTrack_NodeGroups_HXX__
26 #include "FrontTrack_NodesOnGeom.hxx"
27 #include "FrontTrack_Projector.hxx"
32 namespace MEDCoupling {
33 class DataArrayDouble;
40 * \brief Container of node groups.
46 // Load node groups from files
47 void read( const std::vector< std::string >& nodeFiles,
48 const XAO::Xao* xaoGeom,
49 MEDCoupling::DataArrayDouble* nodeCoords );
51 // return number of groups of nodes to move
52 int nbOfGroups() const { return _nodesOnGeom.size(); }
54 // Move nodes of a group in parallel mode
55 void operator() ( const int groupIndex ) const
57 const_cast< FT_NodeGroups* >( this )->projectAndMove( groupIndex );
60 // Project and move nodes of a given group of nodes
61 void projectAndMove( const int groupIndex );
63 // return true if all nodes were successfully relocated
66 // print some statistics on node groups
67 void dumpStat() const;
71 std::vector< FT_NodesOnGeom > _nodesOnGeom;
72 std::vector< FT_Projector > _projectors[2]; // curves and surfaces separately