mor.utility.sceneCreation.addAnimation

addAnimation(node, phase, timeExe, dt, listObjToAnimate)[source]

Add/or not animations defined by ObjToAnimate to the splib.animation.AnimationManagerController thanks to splib.animation.animate

argument

type

definition

node

Sofa.Core.Node

from which node will search & add animation

phase

list(int)

list of 0/1 that according to its index will activate/desactivate
a ObjToAnimate contained in listObjToAnimate

timeExe

sc

correspond to the total SOFA execution duration the animation will occure,
determined with nbIterations (of ReductionAnimations)
multiply by the dt of the current scene

dt

sc

time step of our SOFA scene

listObjToAnimate

list(mor.reduction.container.objToAnimate)

list conaining all the ObjToAnimate that will be use to shake our model

Thanks to the location parameters of an ObjToAnimate, we find the component or Sofa.node it will animate. If its a Sofa.node we search something to animate by default CableConstraint/SurfacePressureConstraint.

Returns:

None