2525#ifndef SOFA_COMPONENT_FORCEFIELD_BEZIER_TRIANGULAR_BENDING_FEM_FORCEFIELD_INL
2626#define SOFA_COMPONENT_FORCEFIELD_BEZIER_TRIANGULAR_BENDING_FEM_FORCEFIELD_INL
2727
28- #include < SofaShells /forcefield/BezierTriangularBendingFEMForceField.h>
28+ #include < Shell /forcefield/BezierTriangularBendingFEMForceField.h>
2929#include < sofa/core/behavior/ForceField.inl>
3030#include < sofa/gl/template.h>
3131#include < sofa/helper/rmath.h>
3838#include < sofa/core/topology/TopologyData.inl>
3939#include < sofa/component/topology/container/dynamic/TriangleSetTopologyContainer.h>
4040#include < sofa/core/visual/VisualParams.h>
41- #include < SofaShells /controller/MeshChangedEvent.h>
41+ #include < Shell /controller/MeshChangedEvent.h>
4242
4343#ifdef _WIN32
4444#include < windows.h>
@@ -145,7 +145,7 @@ template <class DataTypes>void BezierTriangularBendingFEMForceField<DataTypes>::
145145
146146 if (topologyMapper.get () != nullptr )
147147 {
148- sofa::component ::engine::JoinMeshPoints<DataTypes>* jmp = topologyMapper.get ();
148+ shell ::engine::JoinMeshPoints<DataTypes>* jmp = topologyMapper.get ();
149149 if (jmp->f_output_triangles .getValue ().size () == 0 )
150150 {
151151 msg_warning () << " Mapped topology must be triangular. No triangles found." ;
@@ -162,7 +162,7 @@ template <class DataTypes>void BezierTriangularBendingFEMForceField<DataTypes>::
162162 // Check if there is same number of nodes
163163 const VecCoord &rx = restShape.get ()->f_position .getValue ();
164164 if (!mapTopology) {
165- if (rx.size () != this ->mstate ->read (sofa::core::ConstVecCoordId:: position () )->getValue ().size ()) {
165+ if (rx.size () != this ->mstate ->read (sofa::core::vec_id::read_access:: position)->getValue ().size ()) {
166166 msg_warning () << " Different number of nodes in rest shape and mechanical state." ;
167167 }
168168 } else if (rx.size () != topologyMapper.get ()->f_input_position .getValue ().size ()) {
@@ -204,7 +204,7 @@ template <class DataTypes>void BezierTriangularBendingFEMForceField<DataTypes>::
204204 // Check normal count
205205 if (normals.getValue ().size () == 0 ) {
206206 msg_warning () << " No normals defined, assuming flat triangles." ;
207- } else if (normals.getValue ().size () != this ->mstate ->read (sofa::core::ConstVecCoordId:: position () )->getValue ().size ()) {
207+ } else if (normals.getValue ().size () != this ->mstate ->read (sofa::core::vec_id::read_access:: position)->getValue ().size ()) {
208208 msg_warning () << " Normals count doesn't correspond with nodes count." ;
209209 return ;
210210 }
@@ -243,7 +243,7 @@ void BezierTriangularBendingFEMForceField<DataTypes>::initTriangleOnce(const int
243243 // Store indices of each vertex in rest shape
244244 Index a0=a, b0=b, c0=c;
245245 if (mapTopology) {
246- sofa::component ::engine::JoinMeshPoints<DataTypes>* jmp = topologyMapper.get ();
246+ shell ::engine::JoinMeshPoints<DataTypes>* jmp = topologyMapper.get ();
247247
248248 // Get indices in original topology
249249 a0 = jmp->getSrcNodeFromTri (i, a0);
@@ -282,7 +282,7 @@ void BezierTriangularBendingFEMForceField<DataTypes>::initTriangle(const int i)
282282 // if rest shape is fixed but we have mapped topology use it
283283 ? topologyMapper.get ()->f_input_position .getValue ()
284284 // otherwise just take rest shape in mechanical state
285- : this ->mstate ->read (sofa::core::ConstVecCoordId:: position () )->getValue ()
285+ : this ->mstate ->read (sofa::core::vec_id::read_access:: position)->getValue ()
286286 );
287287
288288 const type::vector<Vec3>& norms = (restShape.get () != nullptr )
@@ -1545,7 +1545,7 @@ void BezierTriangularBendingFEMForceField<DataTypes>::addBToMatrix(sofa::lineara
15451545template <class DataTypes >
15461546void BezierTriangularBendingFEMForceField<DataTypes>::handleEvent(sofa::core::objectmodel::Event *event)
15471547{
1548- if ( /* sofa::core::objectmodel::MeshChangedEvent* ev =*/ dynamic_cast <sofa::core ::objectmodel::MeshChangedEvent*>(event))
1548+ if ( /* sofa::core::objectmodel::MeshChangedEvent* ev =*/ dynamic_cast <shell ::objectmodel::MeshChangedEvent*>(event))
15491549 {
15501550 // Update of the rest shape
15511551 // NOTE: the number of triangles should be the same in all topologies
@@ -1566,7 +1566,7 @@ void BezierTriangularBendingFEMForceField<DataTypes>::draw(const core::visual::V
15661566 {
15671567
15681568 // Gets vertices of rest and initial positions respectively
1569- const VecCoord& x0 = this ->mstate ->read (sofa::core::ConstVecCoordId:: position () )->getValue ();
1569+ const VecCoord& x0 = this ->mstate ->read (sofa::core::vec_id::read_access:: position)->getValue ();
15701570
15711571
15721572 type::vector<TriangleInformation>& triangleInf = *(triangleInfo.beginEdit ());
0 commit comments