setBonesToSetupPose method

void setBonesToSetupPose()
inherited

Implementation

void setBonesToSetupPose() {
  final List<Bone> bones = this.bones;
  final int n = bones.length;
  for (int i = 0; i < n; i++) {
    bones[i].setToSetupPose();
  }

  final List<IkConstraint> ikConstraints = this.ikConstraints;
  final int nn = ikConstraints.length;
  for (int i = 0; i < nn; i++) {
    final IkConstraint constraint = ikConstraints[i];
    constraint
      ..bendDirection = constraint.data.bendDirection
      ..mix = constraint.data.mix;
  }

  final List<TransformConstraint> transformConstraints =
      this.transformConstraints;
  final int nnn = transformConstraints.length;
  for (int i = 0; i < nnn; i++) {
    final TransformConstraint constraint = transformConstraints[i];
    final TransformConstraintData data = constraint.data;
    constraint
      ..rotateMix = data.rotateMix
      ..translateMix = data.translateMix
      ..scaleMix = data.scaleMix
      ..shearMix = data.shearMix;
  }

  final List<PathConstraint> pathConstraints = this.pathConstraints;
  final int nnnn = pathConstraints.length;
  for (int i = 0; i < nnnn; i++) {
    final PathConstraint constraint = pathConstraints[i];
    final PathConstraintData data = constraint.data;
    constraint
      ..position = data.position
      ..spacing = data.spacing
      ..rotateMix = data.rotateMix
      ..translateMix = data.translateMix;
  }
}