/
livers.scn
161 lines (152 loc) · 10.9 KB
/
livers.scn
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
<?xml version="1.0" ?>
<Node name="root" gravity="0 -9.81 0" dt="0.02">
<RequiredPlugin name="MultiThreading"/> <!-- Needed to use components [DataExchange] -->
<RequiredPlugin name="Sofa.Component.AnimationLoop"/> <!-- Needed to use components [FreeMotionAnimationLoop] -->
<RequiredPlugin name="Sofa.Component.Collision.Detection.Algorithm"/> <!-- Needed to use components [BVHNarrowPhase BruteForceBroadPhase CollisionPipeline] -->
<RequiredPlugin name="Sofa.Component.Collision.Geometry"/> <!-- Needed to use components [SphereCollisionModel] -->
<RequiredPlugin name="Sofa.Component.Collision.Response.Contact"/> <!-- Needed to use components [CollisionResponse] -->
<RequiredPlugin name="Sofa.Component.Constraint.Lagrangian.Correction"/> <!-- Needed to use components [UncoupledConstraintCorrection] -->
<RequiredPlugin name="Sofa.Component.Constraint.Lagrangian.Solver"/> <!-- Needed to use components [LCPConstraintSolver] -->
<RequiredPlugin name="Sofa.Component.Constraint.Projective"/> <!-- Needed to use components [FixedProjectiveConstraint] -->
<RequiredPlugin name="Sofa.Component.IO.Mesh"/> <!-- Needed to use components [MeshGmshLoader MeshOBJLoader SphereLoader] -->
<RequiredPlugin name="Sofa.Component.LinearSolver.Iterative"/> <!-- Needed to use components [CGLinearSolver] -->
<RequiredPlugin name="Sofa.Component.Mapping.Linear"/> <!-- Needed to use components [BarycentricMapping] -->
<RequiredPlugin name="Sofa.Component.Mass"/> <!-- Needed to use components [DiagonalMass] -->
<RequiredPlugin name="Sofa.Component.ODESolver.Backward"/> <!-- Needed to use components [EulerImplicitSolver] -->
<RequiredPlugin name="Sofa.Component.SolidMechanics.FEM.Elastic"/> <!-- Needed to use components [TetrahedralCorotationalFEMForceField] -->
<RequiredPlugin name="Sofa.Component.StateContainer"/> <!-- Needed to use components [MechanicalObject] -->
<RequiredPlugin name="Sofa.Component.Topology.Container.Dynamic"/> <!-- Needed to use components [TetrahedronSetGeometryAlgorithms TetrahedronSetTopologyContainer] -->
<RequiredPlugin name="Sofa.Component.Collision.Detection.Intersection"/> <!-- Needed to use components [MinProximityIntersection] -->
<RequiredPlugin name="Sofa.GL.Component.Rendering3D"/> <!-- Needed to use components [OglModel] -->
<AnimationLoopParallelScheduler name="mainLoop" nbThreads="0" />
<Node name="scene1" gravity="0 -9.81 0" dt="0.02">
<FreeMotionAnimationLoop name="loop1" />
<CollisionPipeline name="CollisionPipeline" verbose="0" />
<MinProximityIntersection name="Proximity" alarmDistance="2" contactDistance="0.7"/>
<BruteForceBroadPhase/>
<BVHNarrowPhase/>
<CollisionResponse name="collision response" response="PenalityContactForceField" />
<LCPConstraintSolver tolerance="1e-3" maxIt="100" initial_guess="false" build_lcp="true" printLog="0" mu="0.2"/>
<Node name="liver1" gravity="0 -9.81 0">
<EulerImplicitSolver name="cg_odesolver" rayleighStiffness="0.1" rayleighMass="0.1" />
<CGLinearSolver name="linear solver" iterations="25" tolerance="1e-09" threshold="1e-09" />
<MeshGmshLoader name="meshLoader" filename="mesh/liver.msh" translation="10 0 0" />
<TetrahedronSetTopologyContainer name="topo" src="@meshLoader" />
<MechanicalObject name="dofs1" src="@meshLoader" />
<TetrahedronSetGeometryAlgorithms template="Vec3d" name="GeomAlgo" />
<DiagonalMass name="computed using mass density" massDensity="1" />
<TetrahedralCorotationalFEMForceField template="Vec3d" name="FEM" method="large" poissonRatio="0.3" youngModulus="3000" computeGlobalMatrix="0" />
<FixedProjectiveConstraint name="FixedProjectiveConstraint" indices="39" />
<UncoupledConstraintCorrection name="liver1_ConstraintCorrection"/>
<Node name="Visu1" tags="Visual" gravity="0 -9.81 0">
<MeshOBJLoader name="meshLoader_1" filename="mesh/liver-smooth.obj" translation="10 0 0" handleSeams="1" />
<OglModel name="VisualModel" src="@meshLoader_1"/>
<BarycentricMapping name="visual mapping" input="@../dofs1" output="@VisualModel" />
</Node>
<Node name="Surf1" gravity="0 -9.81 0">
<SphereLoader filename="mesh/liver.sph" />
<MechanicalObject name="spheres" position="@[-1].position" />
<SphereCollisionModel name="CollisionModel" listRadius="@[-2].listRadius"/>
<BarycentricMapping name="sphere mapping" input="@../dofs1" output="@spheres" />
</Node>
</Node>
</Node>
<Node name="scene2" gravity="0 -9.81 0" dt="0.02">
<FreeMotionAnimationLoop name="loop2" />
<CollisionPipeline name="CollisionPipeline" verbose="0" />
<MinProximityIntersection name="Proximity" alarmDistance="2" contactDistance="0.7"/>
<BruteForceBroadPhase/>
<BVHNarrowPhase/>
<CollisionResponse name="collision response" response="PenalityContactForceField" />
<LCPConstraintSolver tolerance="1e-3" maxIt="100" initial_guess="false" build_lcp="true" printLog="0" mu="0.2"/>
<Node name="liver2" gravity="0 -9.81 0">
<EulerImplicitSolver name="cg_odesolver" />
<CGLinearSolver name="linear solver" iterations="25" tolerance="1e-09" threshold="1e-09" />
<MeshGmshLoader name="meshLoader" filename="mesh/liver.msh" translation="-10 0 0"/>
<TetrahedronSetTopologyContainer name="topo" src="@meshLoader" />
<MechanicalObject name="dofs2" src="@meshLoader" />
<TetrahedronSetGeometryAlgorithms template="Vec3d" name="GeomAlgo" />
<DiagonalMass name="computed using mass density" massDensity="1" />
<TetrahedralCorotationalFEMForceField template="Vec3d" name="FEM" method="large" poissonRatio="0.3" youngModulus="3000" computeGlobalMatrix="0" />
<FixedProjectiveConstraint name="FixedProjectiveConstraint" indices="64" />
<UncoupledConstraintCorrection name="liver2_ConstraintCorrection"/>
<Node name="Visu2" tags="Visual" gravity="0 -9.81 0">
<MeshOBJLoader name="meshLoader_0" filename="mesh/liver-smooth.obj" translation="-10 0 0" handleSeams="1" />
<OglModel name="VisualModel" src="@meshLoader_0"/>
<BarycentricMapping name="visual mapping" input="@../dofs2" output="@VisualModel" />
</Node>
<Node name="Surf2" gravity="0 -9.81 0">
<SphereLoader filename="mesh/liver.sph" />
<MechanicalObject name="spheres" position="@[-1].position" />
<SphereCollisionModel name="CollisionModel" listRadius="@[-2].listRadius"/>
<BarycentricMapping name="sphere mapping" input="@../dofs2" output="@spheres" />
</Node>
</Node>
</Node>
<Node name="scene3" gravity="0 -9.81 0" dt="0.02">
<FreeMotionAnimationLoop name="loop2" />
<CollisionPipeline name="CollisionPipeline" verbose="0" />
<MinProximityIntersection name="Proximity" alarmDistance="2" contactDistance="0.7"/>
<BruteForceBroadPhase/>
<BVHNarrowPhase/>
<CollisionResponse name="collision response" response="PenalityContactForceField" />
<LCPConstraintSolver tolerance="1e-3" maxIt="100" initial_guess="false" build_lcp="true" printLog="0" mu="0.2"/>
<Node name="liver3" gravity="0 -9.81 0">
<EulerImplicitSolver name="cg_odesolver" />
<CGLinearSolver name="linear solver" iterations="25" tolerance="1e-09" threshold="1e-09" />
<MeshGmshLoader name="meshLoader" filename="mesh/liver.msh" translation="10 10 0"/>
<TetrahedronSetTopologyContainer name="topo" src="@meshLoader" />
<MechanicalObject name="dofs3" src="@meshLoader" />
<TetrahedronSetGeometryAlgorithms template="Vec3d" name="GeomAlgo" />
<DiagonalMass name="computed using mass density" massDensity="1" />
<TetrahedralCorotationalFEMForceField template="Vec3d" name="FEM" method="large" poissonRatio="0.3" youngModulus="3000" computeGlobalMatrix="0" />
<FixedProjectiveConstraint name="FixedProjectiveConstraint" indices="72" />
<UncoupledConstraintCorrection name="liver3_ConstraintCorrection"/>
<Node name="Visu3" tags="Visual" gravity="0 -9.81 0">
<MeshOBJLoader name="meshLoader_3" filename="mesh/liver-smooth.obj" translation="10 10 0" handleSeams="1" />
<OglModel name="VisualModel" src="@meshLoader_3"/>
<BarycentricMapping name="visual mapping" input="@../dofs3" output="@VisualModel" />
</Node>
<Node name="Surf3" gravity="0 -9.81 0">
<SphereLoader filename="mesh/liver.sph" />
<MechanicalObject name="spheres" position="@[-1].position" />
<SphereCollisionModel name="CollisionModel" listRadius="@[-2].listRadius"/>
<BarycentricMapping name="sphere mapping" input="@../dofs3" output="@spheres" />
</Node>
</Node>
</Node>
<Node name="scene4" gravity="0 -9.81 0" dt="0.02">
<FreeMotionAnimationLoop name="loop2" />
<CollisionPipeline name="CollisionPipeline" verbose="0" />
<MinProximityIntersection name="Proximity" alarmDistance="2" contactDistance="0.7"/>
<BruteForceBroadPhase/>
<BVHNarrowPhase/>
<CollisionResponse name="collision response" response="PenalityContactForceField" />
<LCPConstraintSolver tolerance="1e-3" maxIt="100" initial_guess="false" build_lcp="true" printLog="0" mu="0.2"/>
<Node name="liver4" gravity="0 -9.81 0">
<EulerImplicitSolver name="cg_odesolver" />
<CGLinearSolver name="linear solver" iterations="25" tolerance="1e-09" threshold="1e-09" />
<MeshGmshLoader name="meshLoader" filename="mesh/liver.msh" translation="-10 10 0"/>
<TetrahedronSetTopologyContainer name="topo" src="@meshLoader" />
<MechanicalObject name="dofs4" src="@meshLoader" />
<TetrahedronSetGeometryAlgorithms template="Vec3d" name="GeomAlgo" />
<DiagonalMass name="computed using mass density" massDensity="1" />
<TetrahedralCorotationalFEMForceField template="Vec3d" name="FEM" method="large" poissonRatio="0.3" youngModulus="3000" computeGlobalMatrix="0" />
<FixedProjectiveConstraint name="FixedProjectiveConstraint" indices="96" />
<UncoupledConstraintCorrection name="liver4_ConstraintCorrection"/>
<Node name="Visu4" tags="Visual" gravity="0 -9.81 0">
<MeshOBJLoader name="meshLoader_2" filename="mesh/liver-smooth.obj" translation="-10 10 0" handleSeams="1" />
<OglModel name="VisualModel" src="@meshLoader_2"/>
<BarycentricMapping name="visual mapping" input="@../dofs4" output="@VisualModel" />
</Node>
<Node name="Surf4" gravity="0 -9.81 0">
<SphereLoader filename="mesh/liver.sph" />
<MechanicalObject name="spheres" position="@[-1].position" />
<SphereCollisionModel name="CollisionModel" listRadius="@[-2].listRadius"/>
<BarycentricMapping name="sphere mapping" input="@../dofs4" output="@spheres" />
</Node>
</Node>
</Node>
<DataExchange name="exchangeData1" template="vector<Vec3d>" from="@scene1/liver1/dofs1.position" to="@scene2/liver2/dofs2.position" />
<DataExchange name="exchangeData2" template="vector<Vec3d>" from="@scene1/liver1/dofs1.free_position" to="@scene2/liver2/dofs2.free_position" />
</Node>