@@ -230,27 +230,20 @@ protected :
230
230
231
231
void draw (const core::visual::VisualParams* vparams) override ;
232
232
233
+
234
+ /* * Method to initialize @sa TetrahedronRestInformation when a new Tetrahedron is created.
235
+ * Will be set as creation callback in the TetrahedronData @sa tetrahedronInfo
236
+ */
237
+ void createTetrahedronRestInformation (Index, TetrahedronRestInformation& t,
238
+ const core::topology::BaseMeshTopology::Tetrahedron&,
239
+ const sofa::type::vector<Index>&,
240
+ const sofa::type::vector<double >&);
241
+
233
242
type::Mat<3 ,3 ,double > getPhi ( int tetrahedronIndex);
234
243
type::Mat<3 ,3 ,double > getForce ( int tetrahedronIndex);
235
244
TetrahedronData<sofa::type::vector<TetrahedronRestInformation> > tetrahedronInfo;
236
245
EdgeData<sofa::type::vector<EdgeInformation> > edgeInfo;
237
246
238
- class TetrahedronHandler : public TopologyDataHandler <core::topology::BaseMeshTopology::Tetrahedron,sofa::type::vector<TetrahedronRestInformation> >
239
- {
240
- public:
241
- typedef typename MJEDTetrahedralForceField<DataTypes>::TetrahedronRestInformation TetrahedronRestInformation;
242
- TetrahedronHandler (MJEDTetrahedralForceField<DataTypes>* ff,TetrahedronData<sofa::type::vector<TetrahedronRestInformation> >* data )
243
- :TopologyDataHandler<core::topology::BaseMeshTopology::Tetrahedron,sofa::type::vector<TetrahedronRestInformation> >(data)
244
- ,ff(ff)
245
- {
246
- }
247
-
248
- void applyCreateFunction (unsigned int , TetrahedronRestInformation &t, const core::topology::BaseMeshTopology::Tetrahedron
249
- &, const sofa::type::vector<unsigned int > &, const sofa::type::vector<double > &);
250
-
251
- protected:
252
- MJEDTetrahedralForceField<DataTypes>* ff;
253
- };
254
247
protected:
255
248
256
249
// / the array that describes the complete material energy and its derivatives
@@ -261,7 +254,6 @@ protected :
261
254
void testDerivatives ();// a test to check the accuracy of Addforce and AddDforce, it needs the calculus of the total strain energy
262
255
void saveMesh ( const char *filename );
263
256
264
- TetrahedronHandler* tetrahedronHandler;
265
257
VecCoord myposition;
266
258
267
259
};
0 commit comments