Example #1
0
        public void swapRow(int i, int j)
        {
            CVector3 temp = _m[i];

            _m[i] = _m[j];
            _m[j] = temp;
        }
Example #2
0
 public CMatrix3x3 multiplyMatrix(CVector3 a)
 {
     return(new CMatrix3x3(
                new CVector3(_v[0] * a[0], _v[0] * a[1], _v[0] * a[2]),
                new CVector3(_v[1] * a[0], _v[1] * a[1], _v[1] * a[2]),
                new CVector3(_v[2] * a[0], _v[2] * a[1], _v[2] * a[2])));
 }
Example #3
0
 public CVector3 multiplyCopy(CVector3 v)
 {
     return(new CVector3(
                _m[0].multiplyDouble(v),
                _m[1].multiplyDouble(v),
                _m[2].multiplyDouble(v)));
 }
Example #4
0
 public CMatrix3x3(CMatrix3x3 m)
 {
     _m[0] = new CVector3(m._m[0]);
     _m[1] = new CVector3(m._m[1]);
     _m[2] = new CVector3(m._m[2]);
 }
Example #5
0
 public CMatrix3x3(CVector3 a, CVector3 b, CVector3 c)
 {
     _m[0] = new CVector3(a);
     _m[1] = new CVector3(b);
     _m[2] = new CVector3(c);
 }
Example #6
0
 public CMatrix3x3()
 {
     _m[0] = new CVector3(1, 0, 0);
     _m[1] = new CVector3(0, 1, 0);
     _m[2] = new CVector3(0, 0, 1);
 }
Example #7
0
 public double multiplyDouble(CVector3 a)
 {
     return(_v[0] * a[0] + _v[1] * a[1] + _v[2] * a[2]);
 }
Example #8
0
 public CVector3 substractCopy(CVector3 a)
 {
     return(new CVector3(_v[0] - a[0], _v[1] - a[1], _v[2] - a[2]));
 }
Example #9
0
 public void substract(CVector3 a)
 {
     _v[0] -= a[0];
     _v[1] -= a[1];
     _v[2] -= a[2];
 }
Example #10
0
 public CVector3 addCopy(CVector3 a)
 {
     return(new CVector3(_v[0] + a[0], _v[1] + a[1], _v[2] + a[2]));
 }
Example #11
0
 public void add(CVector3 a)
 {
     _v[0] += a[0];
     _v[1] += a[1];
     _v[2] += a[2];
 }
Example #12
0
 public CVector3(CVector3 a)
 {
     _v[0] = a[0];
     _v[1] = a[1];
     _v[2] = a[2];
 }