コード例 #1
0
 public void AddConstraint(int A, int B, double relax)
 {
     var c = new DistanceConstraint(A, B);
     c.Restlength = (Positions[A] - Positions[B]).Length;
     c.RelaxationFactor = relax;
     c.Iterations = Iterations;
     Constraints.Add(c);
 }
コード例 #2
0
        public void AddConstraint(int A, int B, double relax)
        {
            var c = new DistanceConstraint(A, B);

            c.Restlength       = (Positions[A] - Positions[B]).Length;
            c.RelaxationFactor = relax;
            c.Iterations       = Iterations;
            Constraints.Add(c);
        }