yade-dev team mailing list archive
-
yade-dev team
-
Mailing list archive
-
Message #02472
[Branch ~yade-dev/yade/trunk] Rev 1847: State/Mat fix.
------------------------------------------------------------
revno: 1847
committer: Bruno Chareyre <bchareyre@r1arduina>
branch nick: trunk
timestamp: Thu 2009-12-03 11:35:56 +0100
message:
State/Mat fix.
modified:
pkg/dem/Engine/StandAloneEngine/MicroMacroAnalyser.cpp
--
lp:yade
https://code.launchpad.net/~yade-dev/yade/trunk
Your team Yade developers is subscribed to branch lp:yade.
To unsubscribe from this branch go to https://code.launchpad.net/~yade-dev/yade/trunk/+edit-subscription.
=== modified file 'pkg/dem/Engine/StandAloneEngine/MicroMacroAnalyser.cpp'
--- pkg/dem/Engine/StandAloneEngine/MicroMacroAnalyser.cpp 2009-12-01 14:56:39 +0000
+++ pkg/dem/Engine/StandAloneEngine/MicroMacroAnalyser.cpp 2009-12-03 10:35:56 +0000
@@ -7,7 +7,7 @@
*************************************************************************/
-#include<yade/pkg-dem/BodyMacroParameters.hpp>
+#include<yade/pkg-common/ElasticMat.hpp>
#include<yade/pkg-dem/SpheresContactGeometry.hpp>
#include<yade/pkg-dem/ElasticContactInteraction.hpp>
@@ -37,8 +37,6 @@
stateFileName = "./snapshots/state";
}
-
-
void MicroMacroAnalyser::postProcessAttributes(bool deserializing)
{
if(deserializing)
@@ -126,11 +124,11 @@
else {//then it is a sphere (not a wall)
++Ng;
const InteractingSphere* s = YADE_CAST<InteractingSphere*> ( ( *bi )->interactingGeometry.get() );
- const RigidBodyParameters* p = YADE_CAST<RigidBodyParameters*> ( ( *bi )->physicalParameters.get() );
- const Vector3r& pos = p->se3.position;
+ //const GranularMat* p = YADE_CAST<GranularMat*> ( ( *bi )->material.get() );
+ const Vector3r& pos = (*bi)->state->pos;
Real rad = s->radius;
- TS.grains[Idg].sphere = Sphere ( Point ( p->se3.position[0],p->se3.position[1],p->se3.position[2] ), rad );
+ TS.grains[Idg].sphere = Sphere ( Point ( pos[0],pos[1],pos[2] ), rad );
// TS.grains[Idg].translation = trans;
// grains[Idg].rotation = rot;
TS.box.base = Point ( min ( TS.box.base.x(), pos.X()-rad ),
@@ -226,5 +224,5 @@
YADE_PLUGIN((MicroMacroAnalyser));
-YADE_REQUIRE_FEATURE(PHYSPAR);
+