Exemple #1
0
        public Vector6 Scaled(Vector6 other)
        {
            var s = new Vector6(this);

            s.Scale(other);
            return(s);
        }
Exemple #2
0
        public static Vector6 operator+(Vector6 first, Vector6 second)
        {
            var sum = new Vector6();

            sum.positive = first.positive + second.positive;
            sum.negative = first.negative + second.negative;
            return(sum);
        }
Exemple #3
0
        public Vector6 Local2Local(Transform fromT, Transform toT)
        {
            var tV = new Vector6();

            for (int i = 0; i < 3; i++)
            {
                tV.Add(toT.InverseTransformDirection(fromT.TransformDirection(negative.Component(i))));
                tV.Add(toT.InverseTransformDirection(fromT.TransformDirection(positive.Component(i))));
            }
            return(tV);
        }
Exemple #4
0
        public Vector6 InverseTransform(Transform T)
        {
            var tV = new Vector6();

            for (int i = 0; i < 3; i++)
            {
                tV.Add(T.InverseTransformDirection(negative.Component(i)));
                tV.Add(T.InverseTransformDirection(positive.Component(i)));
            }
            return(tV);
        }
Exemple #5
0
 public void Add(Vector6 vec)
 {
     positive += vec.positive;
     negative += vec.negative;
 }
Exemple #6
0
 public Vector6(Vector6 other)
     : this(other.positive, other.negative)
 {
 }
Exemple #7
0
 public void Scale(Vector6 other)
 {
     positive.Scale(other.positive);
     negative.Scale(-other.negative);
 }