Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Apply SOFA PR 4750 changes #312

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ def createScene(rootNode):
bunny.addObject('FastTetrahedralCorotationalForceField', template='Vec3', name='FEM', method='large', poissonRatio='0.3', youngModulus='10000')

bunny.addObject('BoxROI', name='boxROI', box=[-5, -5.0, -5, 5, -4.5, 5], drawBoxes=True)
bunny.addObject('RestShapeSpringsForceField', points='@boxROI.indices', stiffness='1e12')
bunny.addObject('RestShapeSpringsForceField', indices='@boxROI.indices', stiffness='1e12')

bunny.addObject('GenericConstraintCorrection')

Expand Down
4 changes: 2 additions & 2 deletions examples/component/constraint/CableConstraint/Finger.py
Original file line number Diff line number Diff line change
Expand Up @@ -73,10 +73,10 @@ def createScene(rootNode):

# RestShapeSpringsForceField is one way in Sofa to implement fixed point constraint.
# Here the constraints are applied to the DoFs selected by the previously defined BoxROI
finger.addObject('RestShapeSpringsForceField', points=finger.roi.indices.getLinkPath(), stiffness=1e12)
finger.addObject('RestShapeSpringsForceField', indices=finger.roi.indices.getLinkPath(), stiffness=1e12)

# It is also possible to simply set by hand the indices of the points you want to fix.
# finger.addObject('RestShapeSpringsForceField', points=[0, 1, 2, 11, 55], stiffness=1e12)
# finger.addObject('RestShapeSpringsForceField', indices=[0, 1, 2, 11, 55], stiffness=1e12)

finger.addObject('GenericConstraintCorrection')

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ def createScene(rootNode):

# RestShapeSpringsForceField is one way in Sofa to implement fixed point constraint.
# Here the constraints are applied to the DoFs selected by the previously defined BoxROI
finger.addObject('RestShapeSpringsForceField', points='@ROI1.indices', stiffness=1e12)
finger.addObject('RestShapeSpringsForceField', indices='@ROI1.indices', stiffness=1e12)

##########################################
# Cable #
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ def createScene(rootNode):

object = simulation.addChild('Object')
object.addObject('MechanicalObject', template='Vec1', position=0.)
object.addObject("RestShapeSpringsForceField", points=[0], stiffness=1e1)
object.addObject("RestShapeSpringsForceField", indices=[0], stiffness=1e1)
# Try to change the data field "value" from the GUI
object.addObject('JointConstraint', template='Vec1', index=0, value=0, valueType="displacement",
minDisplacement=-pi, maxDisplacement=pi)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ def createScene(rootNode):
youngModulus=500)

accordion.addObject('BoxROI', name='ROI1', box=[-2, -2, 0, 2, 2, 0.5], drawBoxes=True)
accordion.addObject('RestShapeSpringsForceField', points='@ROI1.indices', stiffness=1e12)
accordion.addObject('RestShapeSpringsForceField', indices='@ROI1.indices', stiffness=1e12)
# accordion.addObject('FixedProjectiveConstraint', indices='@ROI1.indices')

accordion.addObject('LinearSolverConstraintCorrection')
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ def createScene(rootNode):

bunny.addObject('BoxROI', name='boxROI', box=[-5, -7, -5, 5, -4.5, 5], drawBoxes=True,
position="@tetras.rest_position", tetrahedra="@container.tetrahedra")
bunny.addObject('RestShapeSpringsForceField', points='@boxROI.indices', stiffness=1e12)
bunny.addObject('RestShapeSpringsForceField', indices='@boxROI.indices', stiffness=1e12)
bunny.addObject('LinearSolverConstraintCorrection')

# bunny/cavity
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ def createScene(rootNode):
tentacle.addObject('TetrahedronFEMForceField', template='Vec3', name='FEM', method='large', poissonRatio=0.3, youngModulus=200)

tentacle.addObject('BoxROI', name='ROI1', box=[[50, -20, 30],[75, 20, 50]], drawBoxes=True)
tentacle.addObject('RestShapeSpringsForceField', points='@ROI1.indices', stiffness=1e12)
tentacle.addObject('RestShapeSpringsForceField', indices='@ROI1.indices', stiffness=1e12)

tentacle.addObject('LinearSolverConstraintCorrection')

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ def addAccordion(node, inverse=False):
accordion.addObject('UniformMass', totalMass=0.030)
accordion.addObject('TetrahedronFEMForceField', template='Vec3', name='FEM', method='large', poissonRatio=0.3, youngModulus=500)
accordion.addObject('BoxROI', name='ROI1', box=[-2, -2, 0, 2, 2, 0.5], drawBoxes=True)
accordion.addObject('RestShapeSpringsForceField', points='@ROI1.indices', stiffness=1e12)
accordion.addObject('RestShapeSpringsForceField', indices='@ROI1.indices', stiffness=1e12)
accordion.addObject('LinearSolverConstraintCorrection')

# Pressure
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ def createScene(rootNode):
youngModulus=500)

accordion.addObject('BoxROI', name='ROI1', box=[-2, -2, 0, 2, 2, 0.5], drawBoxes=True)
accordion.addObject('RestShapeSpringsForceField', points='@ROI1.indices', stiffness=1e12)
accordion.addObject('RestShapeSpringsForceField', indices='@ROI1.indices', stiffness=1e12)

accordion.addObject('LinearSolverConstraintCorrection')

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ def createScene(rootNode):
beam.addObject('BeamInterpolation', name='interpol', crossSectionShape='rectangular', lengthY=5, lengthZ=5,
defaultYoungModulus=1.8e6)
beam.addObject('AdaptiveBeamForceFieldAndMass', name="BeamForceField", computeMass=1, massDensity=0.001)
beam.addObject('RestShapeSpringsForceField', points=0, stiffness=100e10, angularStiffness=100e10)
beam.addObject('RestShapeSpringsForceField', indices=0, stiffness=100e10, angularStiffness=100e10)

# Visualization
visuNode = beam.addChild('visualization')
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,10 +53,10 @@ def createScene(rootNode):

# RestShapeSpringsForceField is one way in Sofa to implement fixed point constraint.
# Here the constraints are applied to the DoFs selected by the previously defined BoxROI
finger.addObject('RestShapeSpringsForceField', points='@ROI.indices', stiffness=1e12)
finger.addObject('RestShapeSpringsForceField', indices='@ROI.indices', stiffness=1e12)

# It is also possible to simply set by hand the indices of the points you want to fix.
# finger.addObject('RestShapeSpringsForceField', points=[0, 1, 2, 11, 55], stiffness=1e12)
# finger.addObject('RestShapeSpringsForceField', indices=[0, 1, 2, 11, 55], stiffness=1e12)

finger.addObject('LinearSolverConstraintCorrection')

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ def createScene(rootNode):

# RestShapeSpringsForceField is one way in Sofa to implement fixed point constraint.
# Here the constraints are applied to the DoFs selected by the previously defined BoxROI
finger.addObject('RestShapeSpringsForceField', points='@ROI.indices', stiffness=1e12)
finger.addObject('RestShapeSpringsForceField', indices='@ROI.indices', stiffness=1e12)

finger.addObject('LinearSolverConstraintCorrection')

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ def createScene(rootNode):

bunny.addObject('BoxROI', name='boxROI', box=[-5, -15, -5, 5, -4.5, 5], drawBoxes=True,
position="@tetras.rest_position", tetrahedra="@container.tetrahedra")
bunny.addObject('RestShapeSpringsForceField', points='@boxROI.indices', stiffness=1e12)
bunny.addObject('RestShapeSpringsForceField', indices='@boxROI.indices', stiffness=1e12)
bunny.addObject('LinearSolverConstraintCorrection')

# bunny/cavity
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ def createScene(rootNode):

bunny.addObject('BoxROI', name='boxROI', box=[-5, -15, -5, 5, -4.5, 5], drawBoxes=True,
position="@tetras.rest_position", tetrahedra="@container.tetrahedra")
bunny.addObject('RestShapeSpringsForceField', points='@boxROI.indices', stiffness=1e12)
bunny.addObject('RestShapeSpringsForceField', indices='@boxROI.indices', stiffness=1e12)
bunny.addObject('LinearSolverConstraintCorrection')

# bunny/cavity
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,11 +63,11 @@ def createScene(rootNode):
showIndices=False, showIndicesScale=4e-5,
position='@../robot/boxROI3.pointsInROI')

robot.addObject('RestShapeSpringsForceField', name='fixed1', points="@boxROI1.indices",
robot.addObject('RestShapeSpringsForceField', name='fixed1', indices="@boxROI1.indices",
external_rest_shape="@RestPositionLeg0/meca0", stiffness=1e3)
robot.addObject('RestShapeSpringsForceField', name='fixed2', points="@boxROI2.indices",
robot.addObject('RestShapeSpringsForceField', name='fixed2', indices="@boxROI2.indices",
external_rest_shape="@RestPositionLeg1/meca1", stiffness=1e3)
robot.addObject('RestShapeSpringsForceField', name='fixed3', points="@boxROI3.indices",
robot.addObject('RestShapeSpringsForceField', name='fixed3', indices="@boxROI3.indices",
external_rest_shape="@RestPositionLeg2/meca2", stiffness=1e3)

###############################
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ def createScene(rootNode):
finger.addObject('UniformMass', totalMass=0.04)
boxROISubTopo = finger.addObject('BoxROI', name='boxROISubTopo', box=[-100, 22.5, -8, -19, 28, 8], strict=False)
boxROI = finger.addObject('BoxROI', name='boxROI', box=[-10, 0, -20, 0, 30, 20], drawBoxes=True)
finger.addObject('RestShapeSpringsForceField', points=boxROI.indices.linkpath, stiffness=1e12, angularStiffness=1e12)
finger.addObject('RestShapeSpringsForceField', indices=boxROI.indices.linkpath, stiffness=1e12, angularStiffness=1e12)

modelSubTopo = finger.addChild('SubTopology')
modelSubTopo.addObject('MeshTopology', position='@loader.position', name='container',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ def createScene(rootNode):
finger.addObject('UniformMass', totalMass=0.04)
boxROISubTopo = finger.addObject('BoxROI', name='boxROISubTopo', box=[-100, 22.5, -8, -19, 28, 8], strict=False)
boxROI = finger.addObject('BoxROI', name='boxROI', box=[-10, 0, -20, 0, 30, 20], drawBoxes=True)
finger.addObject('RestShapeSpringsForceField', points=boxROI.indices.linkpath, stiffness=1e12, angularStiffness=1e12)
finger.addObject('RestShapeSpringsForceField', indices=boxROI.indices.linkpath, stiffness=1e12, angularStiffness=1e12)

modelSubTopo = finger.addChild('SubTopology')
modelSubTopo.addObject('MeshTopology', position='@loader.position', tetrahedra=boxROISubTopo.tetrahedraInROI.linkpath,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ def createScene(rootNode):
finger.addObject('UniformMass', totalMass=0.04)
boxROISubTopo = finger.addObject('BoxROI', name='boxROISubTopo', box=[-100, 22.5, -8, -19, 28, 8], strict=False)
boxROI = finger.addObject('BoxROI', name='boxROI', box=[-10, 0, -20, 0, 30, 20], drawBoxes=True)
finger.addObject('RestShapeSpringsForceField', points=boxROI.indices.linkpath, stiffness=1e12, angularStiffness=1e12)
finger.addObject('RestShapeSpringsForceField', indices=boxROI.indices.linkpath, stiffness=1e12, angularStiffness=1e12)
finger.addObject('GenericConstraintCorrection')

modelSubTopo = finger.addChild('SubTopology')
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ def createScene(rootNode):
boxROI = finger.addObject('BoxROI', name='boxROI', box=[-10, 0, -20, 0, 30, 20], doUpdate=False)
boxROISubTopo = finger.addObject('BoxROI', name='boxROISubTopo', box=[-100, 22.5, -8, -19, 28, 8], strict=False)
finger.addObject('RestShapeSpringsForceField',
points=boxROI.indices.linkpath,
indices=boxROI.indices.linkpath,
stiffness=1e12, angularStiffness=1e12)
finger.addObject('GenericConstraintCorrection')

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ def createScene(rootNode):
finger.integration.rayleighMass = 0.1

finger.addObject('BoxROI', name='boxROI', box=fingersParameters[i]['ROIBox'], drawBoxes=True, doUpdate=False)
finger.addObject('RestShapeSpringsForceField', points='@../Finger1/boxROI.indices', stiffness=1e12,
finger.addObject('RestShapeSpringsForceField', indices='@../Finger1/boxROI.indices', stiffness=1e12,
angularStiffness=1e12)

PneumaticCavity(surfaceMeshFileName=fingersCavitySurfaceMesh,
Expand Down
6 changes: 3 additions & 3 deletions examples/tutorials/PneunetGripper/pneunetgripper-tuto.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ To easily define the indices of the points which will be fixed, we use the boxRO

```python
finger.addObject('BoxROI', name='boxROI', box=[-10, 0, -20, 0, 30, 20])
finger.addObject('RestShapeSpringsForceField', points='@boxROI.indices', stiffness=1e12, angularStiffness=1e12)
finger.addObject('RestShapeSpringsForceField', indices='@boxROI.indices', stiffness=1e12, angularStiffness=1e12)
```

[Step4](details/step4-boundaryConditions.py)
Expand Down Expand Up @@ -286,9 +286,9 @@ def createScene(rootNode):
finger.addObject('BoxROI', name='boxROI', box=[-10, 0, -20, 0, 30, 20])
finger.addObject('BoxROI', name='boxROISubTopo', box=[-100, 22.5, -8, -19, 28, 8], strict=False)
if i == 0:
finger.addObject('RestShapeSpringsForceField', points='@boxROI.indices', stiffness=1e12, angularStiffness=1e12)
finger.addObject('RestShapeSpringsForceField', indices='@boxROI.indices', stiffness=1e12, angularStiffness=1e12)
else:
finger.addObject('RestShapeSpringsForceField', points='@../finger1/boxROI.indices', stiffness=1e12, angularStiffness=1e12)
finger.addObject('RestShapeSpringsForceField', indices='@../finger1/boxROI.indices', stiffness=1e12, angularStiffness=1e12)

finger.addObject('LinearSolverConstraintCorrection', solverName='preconditioner')

Expand Down
4 changes: 2 additions & 2 deletions examples/tutorials/SoftArmGripper/scene.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ def addArm(node):
arm.addObject('MechanicalObject', template='Rigid3', name='dofs', showObject=True, showObjectScale=10)
arm.addObject('UniformMass', indices=[4 * i + 1 for i in range(size)], totalMass=0.003 * size,
showAxisSizeFactor=0.03) # set mass of each piece that connect the ribs
arm.addObject('RestShapeSpringsForceField', stiffness=1e12, angularStiffness=1e12, points=0) # fix base of the arm
arm.addObject('RestShapeSpringsForceField', stiffness=1e12, angularStiffness=1e12, indices=0) # fix base of the arm

# sub topology to allow different ribs thickness for each section
for i in range(params.Arm.nbSection):
Expand Down Expand Up @@ -84,7 +84,7 @@ def addFinger(node, fingerId, translation, rotation):
finger.addObject('TetrahedronFEMForceField', template='Vec3', name='FEM', method='large', poissonRatio=0.3,
youngModulus=1.8e6)
finger.addObject('BoxROI', name='boxROI', box=[-100, -20, -50, 100, 20, 50], drawBoxes=True)
finger.addObject('RestShapeSpringsForceField', points=finger.boxROI.indices.getLinkPath(), stiffness=1e12)
finger.addObject('RestShapeSpringsForceField', indices=finger.boxROI.indices.getLinkPath(), stiffness=1e12)

visu[fingerId] = finger.addChild('Visualization')
visu[fingerId].addObject('MeshSTLLoader', name="loader", filename=params.Simulation.path + "/mesh/finger.stl",
Expand Down
2 changes: 1 addition & 1 deletion examples/tutorials/SoftFingerDesign/details/fixing_box.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,5 +21,5 @@ def __init__(self, parent, target, name='FixingBox',
target.addChild(c)

c.addObject('RestShapeSpringsForceField',
points=self.node.BoxROI.getData('indices').getLinkPath(),
indices=self.node.BoxROI.getData('indices').getLinkPath(),
stiffness=1e12)
2 changes: 1 addition & 1 deletion examples/tutorials/SoftFingerDesign/details/s90_servo.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ def init(self):
angle = self.addChild('Articulation')
angle.addObject('MechanicalObject', name='dofs', template='Vec1', position=[[self.getData('angleIn')]],
rest_position=self.getData('angleIn').getLinkPath())
angle.addObject('RestShapeSpringsForceField', points=0, stiffness=1e9)
angle.addObject('RestShapeSpringsForceField', indices=0, stiffness=1e9)
angle.addObject('UniformMass', totalMass=0.01)

servoWheel = angle.addChild('ServoWheel')
Expand Down
2 changes: 1 addition & 1 deletion examples/tutorials/Tripod/details/fixingbox.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,6 @@ def FixingBox(parent, target, name='FixingBox',
target.addChild(c)

c.addObject('RestShapeSpringsForceField',
points=self.BoxROI.getData('indices').getLinkPath(),
indices=self.BoxROI.getData('indices').getLinkPath(),
stiffness=1e12)
return self
2 changes: 1 addition & 1 deletion examples/tutorials/Tripod/details/maze.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ def createScene(rootNode):
effector.addObject('CGLinearSolver', iterations=100, threshold=1e-5, tolerance=1e-5)
effector.addObject('MechanicalObject', template='Rigid3', name='goalMO', position=[0, 40, 0, 0, 0, 0, 1],
showObject=True, showObjectScale=10)
effector.addObject('RestShapeSpringsForceField', points=0, angularStiffness=1e5, stiffness=1e5)
effector.addObject('RestShapeSpringsForceField', indices=0, angularStiffness=1e5, stiffness=1e5)
effector.addObject('UncoupledConstraintCorrection', compliance='1e-10 1e-10 0 0 1e-10 0 1e-10 ')

# Open maze planning from JSON file
Expand Down
2 changes: 1 addition & 1 deletion examples/tutorials/Tripod/details/s90servo.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ def __init__(self, *args, **kwargs):
angle = self.addChild('Articulation')
angle.addObject('MechanicalObject', name='dofs', template='Vec1', position=[[0]],
rest_position=self.angleIn.getLinkPath())
angle.addObject('RestShapeSpringsForceField', points=0, stiffness=1e9)
angle.addObject('RestShapeSpringsForceField', indices=0, stiffness=1e9)
angle.addObject('UniformMass', totalMass=0.01)

servoWheel = angle.addChild('ServoWheel')
Expand Down
2 changes: 1 addition & 1 deletion examples/tutorials/Tripod/details/step8-maze.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ def EffectorGoal(node, position):
goal.addObject('EulerImplicitSolver', firstOrder=True)
goal.addObject('CGLinearSolver', iterations=100, threshold=1e-12, tolerance=1e-10)
goal.addObject('MechanicalObject', name='goalMO', template='Rigid3', position=position+[0., 0., 0., 1.], showObject=True, showObjectScale=10)
goal.addObject('RestShapeSpringsForceField', points=0, angularStiffness=1e5, stiffness=1e5)
goal.addObject('RestShapeSpringsForceField', indices=0, angularStiffness=1e5, stiffness=1e5)
goal.addObject('UncoupledConstraintCorrection', compliance=[1e-10] * 7)
return goal

Expand Down
2 changes: 1 addition & 1 deletion examples/tutorials/Tripod/myproject/fixingbox.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,6 @@ def FixingBox(parent, target, name='FixingBox',
target.addChild(c)

c.addObject('RestShapeSpringsForceField',
points=self.BoxROI.getData('indices').getLinkPath(),
indices=self.BoxROI.getData('indices').getLinkPath(),
stiffness=1e12)
return self
2 changes: 1 addition & 1 deletion examples/tutorials/Tripod/myproject/maze.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ def createScene(rootNode):
effector.addObject('CGLinearSolver', iterations=100, threshold=1e-5, tolerance=1e-5)
effector.addObject('MechanicalObject', template='Rigid3', name='goalMO', position=[0, 40, 0, 0, 0, 0, 1],
showObject=True, showObjectScale=10)
effector.addObject('RestShapeSpringsForceField', points=0, angularStiffness=1e5, stiffness=1e5)
effector.addObject('RestShapeSpringsForceField', indices=0, angularStiffness=1e5, stiffness=1e5)
effector.addObject('UncoupledConstraintCorrection', compliance='1e-10 1e-10 0 0 1e-10 0 1e-10 ')

# Open maze planning from JSON file
Expand Down
2 changes: 1 addition & 1 deletion examples/tutorials/Tripod/myproject/parts/fixingbox.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,6 @@ def FixingBox(parent, target, name='FixingBox',
target.addChild(c)

c.addObject('RestShapeSpringsForceField',
points=self.BoxROI.getData('indices').getLinkPath(),
indices=self.BoxROI.getData('indices').getLinkPath(),
stiffness=1e12)
return self
2 changes: 1 addition & 1 deletion examples/tutorials/Tripod/myproject/parts/maze.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ def createScene(rootNode):
effector.addObject('CGLinearSolver', iterations=100, threshold=1e-5, tolerance=1e-5)
effector.addObject('MechanicalObject', template='Rigid3', name='goalMO', position=[0, 40, 0, 0, 0, 0, 1],
showObject=True, showObjectScale=10)
effector.addObject('RestShapeSpringsForceField', points=0, angularStiffness=1e5, stiffness=1e5)
effector.addObject('RestShapeSpringsForceField', indices=0, angularStiffness=1e5, stiffness=1e5)
effector.addObject('UncoupledConstraintCorrection', compliance='1e-10 1e-10 0 0 1e-10 0 1e-10 ')

# Open maze planning from JSON file
Expand Down
2 changes: 1 addition & 1 deletion examples/tutorials/Tripod/myproject/parts/s90servo.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ def init(self):
angle = self.addChild('Articulation')
angle.addObject('MechanicalObject', name='dofs', template='Vec1', position=[[0]],
rest_position=self.getData('angleIn').getLinkPath())
angle.addObject('RestShapeSpringsForceField', points=0, stiffness=1e9)
angle.addObject('RestShapeSpringsForceField', indices=0, stiffness=1e9)
angle.addObject('UniformMass', totalMass=0.01)

servoWheel = angle.addChild('ServoWheel')
Expand Down
Loading
Loading