public void SetConstraint(int vID, Vector3d targetPos, double weight) { SoftConstraints[vID] = new SoftConstraintV() { Position = targetPos, Weight = weight }; need_solve_update = true; }
public void SetConstraint(int vID, Vector3d targetPos, double weight, bool bForceToFixedPos = false) { SoftConstraints[vID] = new SoftConstraintV() { Position = targetPos, Weight = weight, PostFix = bForceToFixedPos }; HavePostFixedConstraints = HavePostFixedConstraints || bForceToFixedPos; need_solve_update = true; }